Class CBinaryPayload

Inheritance Relationships

Base Types

Class Documentation

class CBinaryPayload : public eCAL::CPayloadWriter, public eCAL::CPayloadWriter, public eCAL::CPayloadWriter

Public Functions

inline CBinaryPayload(size_t size_)
inline virtual bool WriteFull(void *buf_, size_t len_) override

Perform a full write operation on uninitialized memory.

This virtual function allows derived classes to perform a full write operation when the provisioned memory is uninitialized. Typically, this is the case when a memory file had to be recreated or its size had to be changed.

Parameters:
  • buffer_ – Pointer to the buffer containing the data to be written.

  • size_ – Size of the data to be written.

Returns:

True if the write operation is successful, false otherwise.

inline virtual bool WriteModified(void *buf_, size_t len_) override

Perform a partial write operation to modify existing data.

This virtual function allows derived classes to modify existing data when the provisioned memory is already initialized by a WriteFull call (i.e. contains the data from that full write operation).

The memory can be partially modified and does not have to be completely rewritten, which leads to significantly higher performance (lower latency).

If not implemented (by default), this operation will just call the WriteFull function.

Parameters:
  • buffer_ – Pointer to the buffer containing the data to be modified.

  • size_ – Size of the data to be modified.

Returns:

True if the write/update operation is successful, false otherwise.

inline virtual size_t GetSize() override

Get the size of the required memory.

This virtual function allows derived classes to provide the size of the memory that eCAL needs to allocate.

Returns:

The size of the required memory.

inline CBinaryPayload(size_t size_)
inline virtual bool WriteFull(void *buf_, size_t len_) override

Perform a full write operation on uninitialized memory.

This virtual function allows derived classes to perform a full write operation when the provisioned memory is uninitialized. Typically, this is the case when a memory file had to be recreated or its size had to be changed.

Parameters:
  • buffer_ – Pointer to the buffer containing the data to be written.

  • size_ – Size of the data to be written.

Returns:

True if the write operation is successful, false otherwise.

inline virtual bool WriteModified(void *buf_, size_t len_) override

Perform a partial write operation to modify existing data.

This virtual function allows derived classes to modify existing data when the provisioned memory is already initialized by a WriteFull call (i.e. contains the data from that full write operation).

The memory can be partially modified and does not have to be completely rewritten, which leads to significantly higher performance (lower latency).

If not implemented (by default), this operation will just call the WriteFull function.

Parameters:
  • buffer_ – Pointer to the buffer containing the data to be modified.

  • size_ – Size of the data to be modified.

Returns:

True if the write/update operation is successful, false otherwise.

inline virtual size_t GetSize() override

Get the size of the required memory.

This virtual function allows derived classes to provide the size of the memory that eCAL needs to allocate.

Returns:

The size of the required memory.

inline CBinaryPayload(size_t size_)
inline virtual bool WriteFull(void *buf_, size_t len_) override

Perform a full write operation on uninitialized memory.

This virtual function allows derived classes to perform a full write operation when the provisioned memory is uninitialized. Typically, this is the case when a memory file had to be recreated or its size had to be changed.

Parameters:
  • buffer_ – Pointer to the buffer containing the data to be written.

  • size_ – Size of the data to be written.

Returns:

True if the write operation is successful, false otherwise.

inline virtual bool WriteModified(void *buf_, size_t len_) override

Perform a partial write operation to modify existing data.

This virtual function allows derived classes to modify existing data when the provisioned memory is already initialized by a WriteFull call (i.e. contains the data from that full write operation).

The memory can be partially modified and does not have to be completely rewritten, which leads to significantly higher performance (lower latency).

If not implemented (by default), this operation will just call the WriteFull function.

Parameters:
  • buffer_ – Pointer to the buffer containing the data to be modified.

  • size_ – Size of the data to be modified.

Returns:

True if the write/update operation is successful, false otherwise.

inline virtual size_t GetSize() override

Get the size of the required memory.

This virtual function allows derived classes to provide the size of the memory that eCAL needs to allocate.

Returns:

The size of the required memory.