#include <RawMsgBuf.h>
Public Member Functions | |
void | initialise (unsigned int rawCellSize) |
FUShmRawCell * | rawCell () |
RawMsgBuf (unsigned int size, unsigned int type) | |
unsigned int | usedSize () |
virtual | ~RawMsgBuf () |
Private Attributes | |
FUShmRawCell * | theRawCell_ |
Friends | |
class | MasterQueue |
Message Buffer for Message Queue, holds an entire FUShmRawCell to transport.
Definition at line 23 of file RawMsgBuf.h.
RawMsgBuf::RawMsgBuf | ( | unsigned int | size, |
unsigned int | type | ||
) |
Definition at line 8 of file RawMsgBuf.cc.
: MsgBuf(size, type), theRawCell_(0) { }
RawMsgBuf::~RawMsgBuf | ( | ) | [virtual] |
Definition at line 13 of file RawMsgBuf.cc.
References theRawCell_, and evf::FUShmRawCell::~FUShmRawCell().
{ theRawCell_->~FUShmRawCell(); //delete[] buf_; }
void RawMsgBuf::initialise | ( | unsigned int | rawCellSize | ) |
Construct the Raw cell object in-place in the message buffer
Definition at line 18 of file RawMsgBuf.cc.
References evf::MsgBuf::ptr_, and theRawCell_.
Referenced by evf::RawCache::initialise().
{ // construct the FUShmRawCell at the buffer address // the memory is allocated in the super constructor theRawCell_ = new (ptr_->mtext) FUShmRawCell(rawCellSize); }
FUShmRawCell* evf::RawMsgBuf::rawCell | ( | ) | [inline] |
Returns a pointer to the Raw cell contained in the message buffer
Definition at line 35 of file RawMsgBuf.h.
References evf::MsgBuf::ptr_.
Referenced by evf::FUResourceQueue::buildResource(), and evf::RawCache::releaseMsg().
{ return (FUShmRawCell*) ptr_->mtext; }
unsigned int evf::RawMsgBuf::usedSize | ( | ) | [inline] |
Returns the actually used size in bytes of the buffer.
Definition at line 41 of file RawMsgBuf.h.
References evf::FUShmRawCell::eventSize(), and theRawCell_.
Referenced by evf::FUResourceQueue::buildResource().
{ return theRawCell_->eventSize() + sizeof(long int); }
friend class MasterQueue [friend] |
Reimplemented from evf::MsgBuf.
Definition at line 48 of file RawMsgBuf.h.
FUShmRawCell* evf::RawMsgBuf::theRawCell_ [private] |
Definition at line 46 of file RawMsgBuf.h.
Referenced by initialise(), usedSize(), and ~RawMsgBuf().