![]() |
Habari STOMP Client for OpenMQ 9.0
Object Pascal STOMP client library for OpenMQ
|
A Connection object is a client's active connection to its provider. More...
Public Member Functions | |
| TBTConnection | MakeConnection () |
| A static helper method to create a new connection. | |
| TBTConnection | MakeConnection (const string UserName, const string Password, const string URL) |
| A static helper method to create a new connection. | |
| TBTConnection (const TBTAbstractTransport Transport) | |
| ~TBTConnection () | |
| Boolean | TransportConnected () |
| Is the transport layer connected? | |
| string | StompSessionID () |
| Stomp session ID. | |
| string | StompServerName () |
| Stomp server name. | |
| TStompProtocolVersion | StompProtocolVersion () |
| Stomp protocol version of the current connection. | |
| Stop () | |
| Temporarily stops a connection's delivery of incoming messages. | |
| ISession | CreateSession (const Boolean Transacted, const TAcknowledgementMode AcknowledgementMode) |
| Creates a new session to work on this connection, specifying transacted and acknowledgeMode. | |
| ISession | CreateSession (const TAcknowledgementMode ASessionMode) |
| Creates a new session to work on this connection, specifying sessionMode. | |
| SetDefaultClientID (const string Value) | |
| Sets the default client id that the connection will use if explicitly not set with the SetClientID call. | |
| SetTransformer (const IMessageTransformer Transformer) | |
| Set the message transformer. | |
| SetMapMessageTransformationId (const string ATransformationId) | |
| SetObjectMessageTransformationId (const string ATransformationId) | |
| IMessageTransformer | GetTransformer () |
| Get the message transformer. | |
Public Member Functions inherited from TBTAbstractConnection | |
| TBTAbstractConnection (const TBTAbstractTransport Transport) | |
| Start () | |
| Starts (or restarts) a connection's delivery of incoming messages. | |
| Close () | |
| Closes the connection. | |
Public Attributes | |
| string | ClientID |
| The client identifier for this connection. | |
Public Attributes inherited from TBTAbstractConnection | |
| Boolean | Closed |
| Returns true if the connection is closed. | |
| Boolean | Closing |
| Returns true if the connection is in the process of being closed. | |
| Integer | ConnectTimeOut |
| Connect time out (in milliseconds) | |
| Integer | SendTimeOut |
| Send time out (in milliseconds). | |
| Boolean | Started |
| Returns True if this connection has been started. | |
| TBTAbstractTransport | Transport |
| The transport. | |
Protected Member Functions | |
| StartSessions () | |
| AddSession (const ISession Session) | |
| RemoveSession (const ISession Session) | |
| CheckClientIDWasManuallySpecified () | |
| Ensures that the ClientID was manually specified and not auto-generated. | |
| Dispose () | |
| UnsubscribeDurable (const string Destination, const string Name) | |
| Unsubscribes a durable subscription that has been created by a client. | |
| SendHeartbeat () | |
| Send a heartbeat signal (requires Stomp 1.1) | |
| CheckHeartbeat () | |
| Check for server heartbeat signal (requires Stomp 1.1) | |
| Boolean | ReceiveHeartbeat (Integer ATimeOut) |
| Try to receive server heartbeat. | |
Protected Member Functions inherited from TBTAbstractConnection | |
| StartSessions () | |
| Dispose () | |
| CheckClosed () | |
| Throws an exception if the Connection is already closed. | |
| CheckClosedOrFailed () | |
| Throws an exception if the Connection is already closed or the transport has failed. | |
A Connection object is a client's active connection to its provider.
A connection serves several purposes:
| TBTConnection::TBTConnection | ( | const TBTAbstractTransport | Transport | ) |
| TBTConnection::~TBTConnection | ( | ) |
|
protected |
|
protected |
Ensures that the ClientID was manually specified and not auto-generated.
If the ClientID was not specified this method will throw an exception. This method is used to ensure that the ClientID + durableSubscriber name are used correctly.
|
protected |
Check for server heartbeat signal (requires Stomp 1.1)
| ENoHeartbeat | if an expected server heartbeat was missing |
| ISession TBTConnection::CreateSession | ( | const Boolean | Transacted, |
| const TAcknowledgementMode | AcknowledgementMode ) |
Creates a new session to work on this connection, specifying transacted and acknowledgeMode.
| Transacted | - indicates whether the session is transacted |
| AcknowledgementMode | - indicates whether the consumer or the client will acknowledge any messages it receives. |
| ISession TBTConnection::CreateSession | ( | const TAcknowledgementMode | ASessionMode | ) |
Creates a new session to work on this connection, specifying sessionMode.
| ASessionMode | - indicates whether the consumer or the client will acknowledge any messages it receives. |
|
protected |
| IMessageTransformer TBTConnection::GetTransformer | ( | ) |
Get the message transformer.
| TBTConnection TBTConnection::MakeConnection | ( | ) |
A static helper method to create a new connection.
| TBTConnection TBTConnection::MakeConnection | ( | const string | UserName, |
| const string | Password, | ||
| const string | URL ) |
A static helper method to create a new connection.
|
protected |
Try to receive server heartbeat.
Requires Stomp 1.1
| ATimeOut | timeout |
|
protected |
|
protected |
Send a heartbeat signal (requires Stomp 1.1)
| TBTConnection::SetDefaultClientID | ( | const string | Value | ) |
Sets the default client id that the connection will use if explicitly not set with the SetClientID call.
| TBTConnection::SetMapMessageTransformationId | ( | const string | ATransformationId | ) |
| TBTConnection::SetObjectMessageTransformationId | ( | const string | ATransformationId | ) |
| TBTConnection::SetTransformer | ( | const IMessageTransformer | Transformer | ) |
Set the message transformer.
|
protected |
| TStompProtocolVersion TBTConnection::StompProtocolVersion | ( | ) |
Stomp protocol version of the current connection.
| string TBTConnection::StompServerName | ( | ) |
Stomp server name.
| string TBTConnection::StompSessionID | ( | ) |
Stomp session ID.
| TBTConnection::Stop | ( | ) |
Temporarily stops a connection's delivery of incoming messages.
Delivery can be restarted using the connection's Start method.
When the connection is stopped, delivery to all the connection's message consumers is inhibited: synchronous receives block, and messages are not delivered to message listeners.
| Boolean TBTConnection::TransportConnected | ( | ) |
Is the transport layer connected?
|
protected |
Unsubscribes a durable subscription that has been created by a client.
| Destination | - the destination name |
| Name | - the subscription name |
| string TBTConnection::ClientID |
The client identifier for this connection.
The purpose of the client identifier is to associate a connection and its objects with a state maintained on behalf of the client by a provider. The only such state identified by the API is that required to support durable subscriptions.