xrootd
Loading...
Searching...
No Matches
Classes | Public Member Functions | Private Types | Private Attributes | List of all members
XrdCl::OutQueue Class Reference

A synchronized queue for the outgoing data. More...

#include <XrdClOutQueue.hh>

Classes

struct  MsgHelper
 

Public Member Functions

void PushBack (Message *msg, MsgHandler *handler, time_t expires, bool stateful)
 
void PushFront (Message *msg, MsgHandler *handler, time_t expires, bool stateful)
 
MessagePopMessage (MsgHandler *&handler, time_t &expires, bool &stateful)
 
void PopFront ()
 Remove a message from the front.
 
void Report (XRootDStatus status)
 Report status to all the handlers.
 
bool IsEmpty () const
 Check if the queue is empty.
 
uint64_t GetSize () const
 
uint64_t GetSizeStateless () const
 Return the size of the queue counting only the stateless messages.
 
void GrabExpired (OutQueue &queue, time_t exp=0)
 
void GrabStateful (OutQueue &queue)
 
void GrabItems (OutQueue &queue)
 

Private Types

typedef std::list< MsgHelperMessageList
 

Private Attributes

MessageList pMessages
 

Detailed Description

A synchronized queue for the outgoing data.

Member Typedef Documentation

◆ MessageList

typedef std::list<MsgHelper> XrdCl::OutQueue::MessageList
private

Member Function Documentation

◆ GetSize()

uint64_t XrdCl::OutQueue::GetSize ( ) const
inline

References pMessages.

◆ GetSizeStateless()

uint64_t XrdCl::OutQueue::GetSizeStateless ( ) const

Return the size of the queue counting only the stateless messages.

◆ GrabExpired()

void XrdCl::OutQueue::GrabExpired ( OutQueue queue,
time_t  exp = 0 
)

Remove all the expired messages from the queue and put them in this one

Parameters
queuequeue to take the message from
expexpiration timestamp

◆ GrabItems()

void XrdCl::OutQueue::GrabItems ( OutQueue queue)

Take all the items from the queue and put them in this one

Parameters
queuequeue to take the message

◆ GrabStateful()

void XrdCl::OutQueue::GrabStateful ( OutQueue queue)

Remove all the stateful messages from the queue and put them in this one

Parameters
queuethe queue to take the messages from

◆ IsEmpty()

bool XrdCl::OutQueue::IsEmpty ( ) const
inline

Check if the queue is empty.

References pMessages.

◆ PopFront()

void XrdCl::OutQueue::PopFront ( )

Remove a message from the front.

◆ PopMessage()

Message * XrdCl::OutQueue::PopMessage ( MsgHandler *&  handler,
time_t &  expires,
bool &  stateful 
)

Pop a message from the front of the queue

Returns
0 if there is no message message

◆ PushBack()

void XrdCl::OutQueue::PushBack ( Message msg,
MsgHandler handler,
time_t  expires,
bool  stateful 
)

Add a message to the back the queue

Parameters
msgmessage to be sent
handlerhandler to be notified about the status of the operation
expirestimeout
statefulif true a disconnection will cause an error and removing from the queue, otherwise sending wil be re-attempted

◆ PushFront()

void XrdCl::OutQueue::PushFront ( Message msg,
MsgHandler handler,
time_t  expires,
bool  stateful 
)

Add a message to the front the queue

Parameters
msgmessage to be sent
handlerhandler to be notified about the status of the operation
expirestimeout
statefulif true a disconnection will cause an error and removing from the queue, otherwise sending wil be re-attempted

◆ Report()

void XrdCl::OutQueue::Report ( XRootDStatus  status)

Report status to all the handlers.

Member Data Documentation

◆ pMessages

MessageList XrdCl::OutQueue::pMessages
private

Referenced by GetSize(), and IsEmpty().


The documentation for this class was generated from the following file: