activemq::core::MessageDispatchChannel Class Reference

#include <src/main/activemq/core/MessageDispatchChannel.h>

Inheritance diagram for activemq::core::MessageDispatchChannel:
Inheritance graph
[legend]

Public Member Functions

virtual ~MessageDispatchChannel ()
virtual void enqueue (const Pointer< MessageDispatch > &message)=0
 Add a Message to the Channel behind all pending message.
virtual void enqueueFirst (const Pointer< MessageDispatch > &message)=0
 Add a message to the front of the Channel.
virtual bool isEmpty () const =0
virtual bool isClosed () const =0
virtual bool isRunning () const =0
virtual Pointer< MessageDispatchdequeue (long long timeout)=0
 Used to get an enqueued message.
virtual Pointer< MessageDispatchdequeueNoWait ()=0
 Used to get an enqueued message if there is one queued right now.
virtual Pointer< MessageDispatchpeek () const =0
 Peek in the Queue and return the first message in the Channel without removing it from the channel.
virtual void start ()=0
 Starts dispatch of messages from the Channel.
virtual void stop ()=0
 Stops dispatch of message from the Channel.
virtual void close ()=0
 Close this channel no messages will be dispatched after this method is called.
virtual void clear ()=0
 Clear the Channel, all pending messages are removed.
virtual int size () const =0
virtual std::vector< Pointer
< MessageDispatch > > 
removeAll ()=0
 Remove all messages that are currently in the Channel and return them as a list of Messages.

Constructor & Destructor Documentation

virtual activemq::core::MessageDispatchChannel::~MessageDispatchChannel (  )  [virtual]

Member Function Documentation

virtual void activemq::core::MessageDispatchChannel::clear (  )  [pure virtual]

Clear the Channel, all pending messages are removed.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual void activemq::core::MessageDispatchChannel::close (  )  [pure virtual]

Close this channel no messages will be dispatched after this method is called.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual Pointer<MessageDispatch> activemq::core::MessageDispatchChannel::dequeue ( long long  timeout  )  [pure virtual]

Used to get an enqueued message.

The amount of time this method blocks is based on the timeout value. - if timeout==-1 then it blocks until a message is received. - if timeout==0 then it it tries to not block at all, it returns a message if it is available - if timeout>0 then it blocks up to timeout amount of time. Expired messages will consumed by this method.

Returns:
null if we timeout or if the consumer is closed.
Exceptions:
ActiveMQException 

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual Pointer<MessageDispatch> activemq::core::MessageDispatchChannel::dequeueNoWait (  )  [pure virtual]

Used to get an enqueued message if there is one queued right now.

If there is no waiting message than this method returns Null.

Returns:
a message if there is one in the queue.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual void activemq::core::MessageDispatchChannel::enqueue ( const Pointer< MessageDispatch > &  message  )  [pure virtual]

Add a Message to the Channel behind all pending message.

Parameters:
message - The message to add to the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual void activemq::core::MessageDispatchChannel::enqueueFirst ( const Pointer< MessageDispatch > &  message  )  [pure virtual]

Add a message to the front of the Channel.

Parameters:
message - The Message to add to the front of the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual bool activemq::core::MessageDispatchChannel::isClosed (  )  const [pure virtual]
virtual bool activemq::core::MessageDispatchChannel::isEmpty (  )  const [pure virtual]
Returns:
true if there are no messages in the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual bool activemq::core::MessageDispatchChannel::isRunning (  )  const [pure virtual]
Returns:
true if the Channel currently running and will dequeue message.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual Pointer<MessageDispatch> activemq::core::MessageDispatchChannel::peek (  )  const [pure virtual]

Peek in the Queue and return the first message in the Channel without removing it from the channel.

Returns:
a message if there is one in the queue.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual std::vector<Pointer<MessageDispatch> > activemq::core::MessageDispatchChannel::removeAll (  )  [pure virtual]

Remove all messages that are currently in the Channel and return them as a list of Messages.

Returns:
a list of Messages that was previously in the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual int activemq::core::MessageDispatchChannel::size (  )  const [pure virtual]
Returns:
the number of Messages currently in the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual void activemq::core::MessageDispatchChannel::start (  )  [pure virtual]

Starts dispatch of messages from the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.

virtual void activemq::core::MessageDispatchChannel::stop (  )  [pure virtual]

Stops dispatch of message from the Channel.

Implemented in activemq::core::FifoMessageDispatchChannel, and activemq::core::SimplePriorityMessageDispatchChannel.


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

Generated on 1 Dec 2014 for activemq-cpp-3.8.2 by  doxygen 1.6.1