32 pMessages.push_back(
MsgHelper( msg, handler, expires, stateful ) );
43 pMessages.push_front(
MsgHelper( msg, handler, expires, stateful ) );
53 if( pMessages.empty() )
60 pMessages.pop_front();
69 pMessages.pop_front();
77 MessageList::iterator it;
78 for( it = pMessages.begin(); it != pMessages.end(); ++it )
79 it->handler->OnStatusReady( it->msg, status );
88 MessageList::const_iterator it;
89 for( it = pMessages.begin(); it != pMessages.end(); ++it )
101 MessageList::iterator it;
102 for( it = queue.pMessages.begin(); it != queue.pMessages.end(); )
104 if( it->expires > exp )
109 pMessages.push_back( *it );
110 it = queue.pMessages.erase( it );
120 MessageList::iterator it;
121 for( it = queue.pMessages.begin(); it != queue.pMessages.end(); )
128 pMessages.push_back( *it );
129 it = queue.pMessages.erase( it );
138 MessageList::iterator it;
139 for( it = queue.pMessages.begin(); it != queue.pMessages.end(); ++it )
140 pMessages.push_back( *it );
141 queue.pMessages.clear();
The message representation used throughout the system.
A synchronized queue for the outgoing data.
void PushFront(Message *msg, MsgHandler *handler, time_t expires, bool stateful)
void GrabStateful(OutQueue &queue)
void PopFront()
Remove a message from the front.
void GrabExpired(OutQueue &queue, time_t exp=0)
void GrabItems(OutQueue &queue)
Message * PopMessage(MsgHandler *&handler, time_t &expires, bool &stateful)
Get a message from the front of the queue.
void PushBack(Message *msg, MsgHandler *handler, time_t expires, bool stateful)
void Report(XRootDStatus status)
Report status to all the handlers.
uint64_t GetSizeStateless() const
Return the size of the queue counting only the stateless messages.