F.70 ctThrdQueueMlen
Returns the length of the message at the beginning of a queue.
Short Name
ctThrdQueueMlen
TYPE
Threading function
DECLARATION
NINT ctThrdQueueMlen(NINT qid, LONG timeout)DESCRIPTION
Returns the length of the message at the head (beginning) of the queue, waiting up to timeout milliseconds if the queue is empty. Ordinarily, this call would be followed by a call to ctThrdQueueRead with a zero timeout. If ctThrdLIFOWrite is used, ctThrdQueueMlen is of little value because the head of the queue can change before the message length primitive can be or'ed in a subsequent queue read.
RETURN
See Appendix A "c-tree Plus Error Codes" of the c-tree Plus Programmer's Reference Guide for a complete listing of valid c-tree Plus error values.
EXAMPLE
See ctmtap.c for ctThrdQueueMlen examples.
LIMITATIONS
Can only be used with a ctThrd library.
SEE ALSO
ctThrdQueueClose, ctThrdQueueCount, ctThrdLIFOWrite, ctThrdQueueOpen, ctThrdQueueRead, and ctThrdQueueWrite.
|
FairCom Corporation www.faircom.com |