|
|
This class is a queue for SCTP Data Arrive notification data.
ChunkArrivalQueue ()
| ChunkArrivalQueue |
Constructor.
~ChunkArrivalQueue ()
| ~ChunkArrivalQueue |
Destructor.
bool addChunk (const unsigned int assocID,
const unsigned short streamID,
const unsigned int protoID,
const size_t length,
const unsigned int unordered,
AssociationControlData* controlData,
const size_t controlDataLength,
const AssociationStatus& status)
| addChunk |
Add chunk to tail of queue. Note: The controlData pointer itself is stored. No copy will be made!
Parameters:
assocID | Association ID. |
streamID | Stream ID. |
protoID | Protocol ID. |
length | Length of chunk. |
unordered | Unordered flag. |
controlData | Pointer to control data. |
controlDataLength | Length of control data. |
status | Association status. |
Returns: true, if add was successful; false otherwise (out of memory).
bool pushChunk (const unsigned int assocID,
const unsigned short streamID,
const unsigned int protoID,
const size_t length,
const unsigned int unordered,
AssociationControlData* controlData,
const size_t controlDataLength,
const AssociationStatus& status)
| pushChunk |
Add chunk to top of queue. Note: The controlData pointer itself is stored. No copy will be made!
Parameters:
assocID | Association ID. |
streamID | Stream ID. |
protoID | Protocol ID. |
length | Length of chunk. |
unordered | Unordered flag. |
controlData | Pointer to control data. |
controlDataLength | Length of control data. |
status | Association status. |
Returns: true, if push was successful; false otherwise (out of memory).
bool getChunk (unsigned int& assocID,
unsigned short& streamID,
unsigned int& protoID,
size_t& length,
unsigned int& unordered,
AssociationControlData*& controlData,
size_t& controlDataLength,
AssociationStatus& status)
| getChunk |
Get chunk from top of queue and remove it. Note: The control data has to be freed by the user of this function!
Parameters:
assocID | Reference to store Association ID. |
streamID | Reference to store Stream ID. |
protoID | Reference to store Protocol ID. |
length | Reference to store Length of chunk. |
unordered | Reference to store Unordered flag. |
controlData | Reference to store Pointer to control data. |
controlDataLength | Reference to store Length of control data. |
status | Reference to store Association status. |
Returns: true, if get was successful; false otherwise (queue is empty).
void waitForChunk ()
| waitForChunk |
Wait for new chunk.
void signal ()
| signal |
Signalize, that new chunk has arrived.
void flush ()
| flush |
Flush queue.