Apache Qpid - AMQP Messaging for Java JMS, C++, Python, Ruby, and .NET | Apache Qpid Documentation |
#include <qpid/messaging/Receiver.h>
Public Member Functions | |
Receiver (ReceiverImpl *impl=0) | |
Receiver (const Receiver &) | |
~Receiver () | |
Receiver & | operator= (const Receiver &) |
bool | get (Message &message, Duration timeout=Duration::FOREVER) |
Retrieves a message from this Receiver's local queue or waits for up to the specified timeout for a message to become available. More... | |
Message | get (Duration timeout=Duration::FOREVER) |
Retrieves a message from this Receiver's local queue or waits for up to the specified timeout for a message to become available. More... | |
bool | fetch (Message &message, Duration timeout=Duration::FOREVER) |
Retrieves a message from this Receiver's subscription or waits for up to the specified timeout for one to become available. More... | |
Message | fetch (Duration timeout=Duration::FOREVER) |
Retrieves a message for this Receiver's subscription or waits for up to the specified timeout for one to become available. More... | |
void | setCapacity (uint32_t) |
Sets the capacity for the Receiver. More... | |
uint32_t | getCapacity () |
uint32_t | getAvailable () |
uint32_t | getUnsettled () |
void | close () |
Cancels this Receiver. More... | |
bool | isClosed () const |
Return true if the Receiver was closed by a call to close(). More... | |
const std::string & | getName () const |
Returns the name of this Receiver. More... | |
Session | getSession () const |
Returns a handle to the session associated with this Receiver. More... | |
Address | getAddress () const |
Returns an address for this Receiver. More... | |
QPID_MESSAGING_INLINE_EXTERN bool | isValid () const |
QPID_MESSAGING_INLINE_EXTERN bool | isNull () const |
QPID_MESSAGING_INLINE_EXTERN | operator bool () const |
Conversion to bool supports idiom if (handle) { handle->... More... | |
QPID_MESSAGING_INLINE_EXTERN bool | operator! () const |
Operator ! supports idiom if (!handle) { do_if_handle_is_null(); }. More... | |
void | swap (Handle< ReceiverImpl > &h) |
Protected Types | |
typedef ReceiverImpl | Impl |
Protected Attributes | |
Impl * | impl |
Interface through which messages are received.
Definition at line 45 of file Receiver.h.
|
protectedinherited |
qpid::messaging::Receiver::Receiver | ( | ReceiverImpl * | impl = 0 | ) |
qpid::messaging::Receiver::Receiver | ( | const Receiver & | ) |
qpid::messaging::Receiver::~Receiver | ( | ) |
void qpid::messaging::Receiver::close | ( | ) |
Cancels this Receiver.
Message qpid::messaging::Receiver::fetch | ( | Duration | timeout = Duration::FOREVER | ) |
Retrieves a message for this Receiver's subscription or waits for up to the specified timeout for one to become available.
Unlike get(), this method will check with the server that there is no message for the subscription this receiver is serving before throwing an exception.
NoMessageAvailable | if there is no message available after waiting for the specified timeout, or if the Receiver is closed, in which case isClose() will be true. |
bool qpid::messaging::Receiver::fetch | ( | Message & | message, |
Duration | timeout = Duration::FOREVER |
||
) |
Retrieves a message from this Receiver's subscription or waits for up to the specified timeout for one to become available.
Unlike get(), this method will check with the server that there is no message for the subscription this receiver is serving before returning false.
Message qpid::messaging::Receiver::get | ( | Duration | timeout = Duration::FOREVER | ) |
Retrieves a message from this Receiver's local queue or waits for up to the specified timeout for a message to become available.
NoMessageAvailable | if there is no message to give after waiting for the specified timeout, or if the Receiver is closed, in which case isClosed() will be true. |
bool qpid::messaging::Receiver::get | ( | Message & | message, |
Duration | timeout = Duration::FOREVER |
||
) |
Retrieves a message from this Receiver's local queue or waits for up to the specified timeout for a message to become available.
uint32_t qpid::messaging::Receiver::getAvailable | ( | ) |
uint32_t qpid::messaging::Receiver::getCapacity | ( | ) |
const std::string& qpid::messaging::Receiver::getName | ( | ) | const |
Returns the name of this Receiver.
Session qpid::messaging::Receiver::getSession | ( | ) | const |
Returns a handle to the session associated with this Receiver.
uint32_t qpid::messaging::Receiver::getUnsettled | ( | ) |
bool qpid::messaging::Receiver::isClosed | ( | ) | const |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
void qpid::messaging::Receiver::setCapacity | ( | uint32_t | ) |
|
inlineinherited |
|
protectedinherited |