eRPC API Reference
Rev. 1.12.0
NXP Semiconductors
|
Abstract interface for message buffer factory. More...
#include <erpc_message_buffer.hpp>
Public Member Functions | |
MessageBufferFactory (void) | |
Constructor. More... | |
virtual | ~MessageBufferFactory (void) |
MessageBufferFactory destructor. | |
virtual MessageBuffer | create (void)=0 |
This function creates new message buffer. More... | |
MessageBuffer | create (uint8_t reserveHeaderSize) |
This function creates new message buffer with reserved bytes at the beginning. More... | |
virtual bool | createServerBuffer (void) |
This function informs server if it has to create buffer for received message. More... | |
virtual erpc_status_t | prepareServerBufferForSend (MessageBuffer &message, uint8_t reserveHeaderSize=0) |
This function is preparing output buffer on server side. More... | |
virtual void | dispose (MessageBuffer *buf)=0 |
This function disposes message buffer. More... | |
Abstract interface for message buffer factory.
MessageBufferFactory::MessageBufferFactory | ( | void | ) |
Constructor.
This function initializes object attributes.
|
pure virtual |
This function creates new message buffer.
Implemented in StaticMessageBufferFactory, RPMsgMessageBufferFactory, and DynamicMessageBufferFactory.
MessageBuffer MessageBufferFactory::create | ( | uint8_t | reserveHeaderSize | ) |
This function creates new message buffer with reserved bytes at the beginning.
Reserved bytes can be used by transport to write transport related header file data.
[in] | reserveHeaderSize | Reserved amount of bytes at the beginning of message buffer. |
|
virtual |
This function informs server if it has to create buffer for received message.
Reimplemented in RPMsgMessageBufferFactory.
|
virtual |
This function is preparing output buffer on server side.
This function do decision if this function want reuse buffer, or use new buffer. In case of using new buffer function has to free given buffer.
[in] | message | MessageBuffer which can be reused. |
[in] | reserveHeaderSize | Reserved amount of bytes at the beginning of message buffer. |
Reimplemented in RPMsgMessageBufferFactory.
|
pure virtual |
This function disposes message buffer.
[in] | buf | MessageBuffer to dispose. |
Implemented in StaticMessageBufferFactory, RPMsgMessageBufferFactory, and DynamicMessageBufferFactory.