44 for (
unsigned int i = 0;
i <
nMsgs_;
i++) {
65 while (freeSlot == -1) {
66 cout <<
"NO FREE SLOTS IN CACHE!" << endl;
73 return msgs_[freeSlot];
82 if (
msgs_[i]->rawCell()->fuResourceId() == fuResourceId)
90 cout <<
"RAW MSG BUF corresponding to fuResourceId = " << fuResourceId
91 <<
"not found in internal allocation list!" << endl;
95 initialised_(
false), nMsgs_(0) {
100 for (
unsigned int i = 0;
i <
nMsgs_;
i++)
107 for (
unsigned int i = 0;
i <
nMsgs_;
i++)
109 if (
msgs_[i] == rmb) {
113 cout <<
"ERROR: Raw Message Buffer to free at address: " << rmb
114 <<
" not found in internal allocation list!" << endl;
118 cout <<
"Raw Cache usage: ";
119 for (
unsigned int i = 0;
i <
nMsgs_;
i++)
RawMsgBuf * getMsgToWrite()
static RawCache * getInstance()
void releaseMsg(unsigned int fuResourceId)
static const unsigned int RAW_MESSAGE_TYPE
void initialise(unsigned int nMsgs, unsigned int cellSize)
void setFree(RawMsgBuf *rawCell)
void initialise(unsigned int rawCellSize)
static RawCache * instance_