Back to Adaptive Vision Studio website

You are here: Start » Filter Reference » System » Binary Data » WriteBufferToBuffer

WriteBufferToBuffer


Module: FoundationLite

Writes content of a source byte buffer into other byte buffer.

Name Type Range Description
inBuffer ByteBuffer Initial buffer to be expanded
inOffset Integer* 0 - Write destination position
inSourceBuffer ByteBuffer Buffer containing source data to be copied
inSourceOffset Integer 0 - Copy start position in source data
inSourceLength Integer* 0 - Length of data to be copied in bytes
outBuffer ByteBuffer Resulting data

Description

This filter is intended for transferring raw binary data between byte buffers.

Source data is acquired from the buffer at the inSourceBuffer input, starting at the position determined by the inSourceOffset input (in bytes) and limited to the length determined by the inSourceLength input. When the inSourceLength input is set to Auto source data is read from the start position up to the end of inSourceBuffer.

Resulting ByteBuffer data on the outBuffer output is created by expanding data from buffer on the inBuffer input. Data is written starting at the position specified by the inOffset input (in bytes). When written data spans beyond the end of the input buffer the resulting buffer length is expanded (event when inOffset points beyond the end of the input buffer). When the inOffset input is set to Auto data is written at the end of the input buffer.

Errors

This filter can throw an exception to report error. Read how to deal with errors in Error Handling.

List of possible exceptions:

Error type Description
IoError Reading beyond the end of the source byte buffer.
Data block specified by the inSourceOffset and inSourceLength inputs spans beyond the end of the source byte buffer (inSourceBuffer).
IoError Resulting buffer size is too large.

Complexity Level

This filter is available on Basic Complexity Level.

Filter Group

This filter is member of WriteToBuffer filter group.