eRPC API Reference  Rev. 1.12.0
NXP Semiconductors
RPMsgMessageBufferFactory Class Reference

RPMsg zero copy message buffer factory. More...

+ Inheritance diagram for RPMsgMessageBufferFactory:
+ Collaboration diagram for RPMsgMessageBufferFactory:

Public Member Functions

 RPMsgMessageBufferFactory (struct rpmsg_lite_instance *rpmsg)
 Constructor. More...
 
virtual ~RPMsgMessageBufferFactory (void)
 Destructor.
 
virtual MessageBuffer create (void)
 This function creates new message buffer. More...
 
virtual void dispose (MessageBuffer *buf)
 This function disposes message buffer. More...
 
virtual erpc_status_t prepareServerBufferForSend (MessageBuffer &message, uint8_t reserveHeaderSize=0)
 This function is preparing output buffer on server side. More...
 
virtual bool createServerBuffer (void)
 This function informs server if it has to create buffer for received message. More...
 
- Public Member Functions inherited from erpc::MessageBufferFactory
 MessageBufferFactory (void)
 Constructor. More...
 
virtual ~MessageBufferFactory (void)
 MessageBufferFactory destructor.
 
MessageBuffer create (uint8_t reserveHeaderSize)
 This function creates new message buffer with reserved bytes at the beginning. More...
 

Protected Attributes

struct rpmsg_lite_instance * m_rpmsg
 

Detailed Description

RPMsg zero copy message buffer factory.

Constructor & Destructor Documentation

RPMsgMessageBufferFactory::RPMsgMessageBufferFactory ( struct rpmsg_lite_instance *  rpmsg)
inlineexplicit

Constructor.

Parameters
[in]rpmsgPointer to instance of RPMSG lite.

Member Function Documentation

virtual MessageBuffer RPMsgMessageBufferFactory::create ( void  )
inlinevirtual

This function creates new message buffer.

Returns
MessageBuffer New created MessageBuffer.

Implements erpc::MessageBufferFactory.

virtual void RPMsgMessageBufferFactory::dispose ( MessageBuffer buf)
inlinevirtual

This function disposes message buffer.

Parameters
[in]bufMessageBuffer to dispose.

Implements erpc::MessageBufferFactory.

virtual erpc_status_t RPMsgMessageBufferFactory::prepareServerBufferForSend ( MessageBuffer message,
uint8_t  reserveHeaderSize = 0 
)
inlinevirtual

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.

Parameters
[in]messageMessageBuffer which can be reused.
[in]reserveHeaderSizeReserved amount of bytes at the beginning of message buffer.

Reimplemented from erpc::MessageBufferFactory.

virtual bool RPMsgMessageBufferFactory::createServerBuffer ( void  )
inlinevirtual

This function informs server if it has to create buffer for received message.

Returns
Has to return TRUE when server need create buffer for receiving message.

Reimplemented from erpc::MessageBufferFactory.

Member Data Documentation

struct rpmsg_lite_instance* RPMsgMessageBufferFactory::m_rpmsg
protected

Pointer to instance of RPMSG lite.


The documentation for this class was generated from the following file: