Apache Qpid - AMQP Messaging for Java JMS, C++, Python, Ruby, and .NET | Apache Qpid Documentation |
The Connection class represents a connection to a QPID broker that can be used by agents and consoles, possibly multiple at the same time. More...
#include <qmf/Connection.h>
Public Member Functions | |
QMF_EXTERN | Connection (const ConnectionSettings &settings, const ConnectionListener *listener=0) |
Creates a connection object and begins the process of attempting to connect to the QPID broker. | |
QMF_EXTERN | ~Connection () |
Destroys a connection, causing the connection to be closed. | |
QMF_EXTERN void | setAdminState (bool enabled) |
Set the administrative state of the connection (enabled or disabled). | |
QMF_EXTERN ConnectionState | getOperState () const |
Return the current operational state of the connection (up or down). | |
QMF_EXTERN const char * | getLastError () const |
Get the error message from the last failure to connect. |
The Connection class represents a connection to a QPID broker that can be used by agents and consoles, possibly multiple at the same time.
Definition at line 74 of file Connection.h.
QMF_EXTERN qmf::Connection::Connection | ( | const ConnectionSettings & | settings, | |
const ConnectionListener * | listener = 0 | |||
) |
Creates a connection object and begins the process of attempting to connect to the QPID broker.
settings | The settings that control how the connection is set up. | |
listener | An optional pointer to a subclass of ConnectionListener to receive notifications of events related to this connection. |
QMF_EXTERN qmf::Connection::~Connection | ( | ) |
Destroys a connection, causing the connection to be closed.
QMF_EXTERN const char* qmf::Connection::getLastError | ( | ) | const |
Get the error message from the last failure to connect.
QMF_EXTERN ConnectionState qmf::Connection::getOperState | ( | ) | const |
Return the current operational state of the connection (up or down).
QMF_EXTERN void qmf::Connection::setAdminState | ( | bool | enabled | ) |
Set the administrative state of the connection (enabled or disabled).
enabled | True => enable connection, False => disable connection |