ActiveMQXAConnection (ActiveMQ 1.1 API)
Keywords: org.codehaus.activemq.ActiveMQXAConnection class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.codehaus.activemq
Class ActiveMQXAConnection

    java.lang.Object
      org.codehaus.activemq.ActiveMQConnection
          org.codehaus.activemq.ActiveMQXAConnection

All Implemented Interfaces:
  CapacityMonitorEventListener, Connection, ExceptionListener, PacketListener, QueueConnection, StatsCapable, TopicConnection, TransportStatusEventListener, XAConnection, XAQueueConnection, XATopicConnection

public class ActiveMQXAConnection
extends ActiveMQConnection
implements XATopicConnection, XAQueueConnection, XAConnection

The XAConnection interface extends the capability of Connection by providing an XASession (optional).

The XAConnection interface is optional. JMS providers are not required to support this interface. This interface is for use by JMS providers to support transactional environments. Client programs are strongly encouraged to use the transactional support available in their environment, rather than use these XA interfaces directly.

Version:
  $Revision: 1.6 $
See Also:
  `Connection`, `ConnectionFactory`, `QueueConnection`, `TopicConnection`, `TopicConnectionFactory`, `QueueConnection`, `QueueConnectionFactory`

Field Summary

Fields inherited from class org.codehaus.activemq.ActiveMQConnection
`clientID, consumerIdGenerator, DEFAULT_PASSWORD, DEFAULT_URL, DEFAULT_USER, packetIdGenerator, useAsyncSend`

Constructor Summary
`ActiveMQXAConnection(ActiveMQConnectionFactory factory, String theUserName, String thePassword)`
`ActiveMQXAConnection(ActiveMQConnectionFactory factory, String theUserName, String thePassword, TransportChannel transportChannel)`

Method Summary
`protected ActiveMQXASession` | `createActiveMQXASession()`
`QueueSession` | `createQueueSession(boolean transacted, int acknowledgeMode)` Creates a `QueueSession` object.
`Session` | `createSession(boolean transacted, int acknowledgeMode)` Creates a `Session` object.
`TopicSession` | `createTopicSession(boolean transacted, int acknowledgeMode)` Creates a `TopicSession` object.
`XAQueueSession` | `createXAQueueSession()`
`XASession` | `createXASession()`
`XATopicSession` | `createXATopicSession()`
`String` | `getResourceManagerId()`

Methods inherited from class org.codehaus.activemq.ActiveMQConnection
`addConnectionConsumer, addMessageDispatcher, addSession, asyncSendPacket, asyncSendPacket, capacityChanged, checkClientIDWasManuallySpecified, checkClosed, clearMessagesInProgress, close, consume, createConnectionConsumer, createConnectionConsumer, createConnectionConsumer, createDurableConnectionConsumer, doReconnect, ensureClientIDInitialised, generateSessionId, getClientID, getConnectionMemoryLimit, getConnectionStats, getExceptionListener, getInitializedClientID, getMemoryBoundedQueue, getMetaData, getNextConsumerNumber, getPrefetchPolicy, getSendCloseTimeout, getSendConnectionInfoTimeout, getStats, getTransportChannel, handleAsyncException, isStarted, isUseAsyncSend, makeConnection, makeConnection, makeConnection, onException, removeConnectionConsumer, removeMessageDispatcher, removeSession, sendConnectionInfoToBroker, sendConnectionInfoToBroker, setClientID, setConnectionMemoryLimit, setExceptionListener, setPrefetchPolicy, setSendCloseTimeout, setSendConnectionInfoTimeout, setUseAsyncSend, start, statusChanged, stop, syncSendPacket, syncSendPacket, syncSendRequest`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface javax.jms.Connection
`close, createConnectionConsumer, createDurableConnectionConsumer, getClientID, getExceptionListener, getMetaData, setClientID, setExceptionListener, start, stop`

Methods inherited from interface javax.jms.TopicConnection
`createConnectionConsumer, createDurableConnectionConsumer`

Methods inherited from interface javax.jms.QueueConnection
`createConnectionConsumer`

Constructor Detail

### ActiveMQXAConnection

    public ActiveMQXAConnection(ActiveMQConnectionFactory factory,
                                String theUserName,
                                String thePassword,
                                TransportChannel transportChannel)
                         throws JMSException

### ActiveMQXAConnection

    public ActiveMQXAConnection(ActiveMQConnectionFactory factory,
                                String theUserName,
                                String thePassword)
                         throws JMSException

Method Detail

### createXASession

    public XASession createXASession()
                              throws JMSException

  Specified by:
    `createXASession` in interface `XAConnection`
  Throws:
    `JMSException`

### createQueueSession

    public QueueSession createQueueSession(boolean transacted,
                                           int acknowledgeMode)
                                    throws JMSException

  Description copied from class: `ActiveMQConnection`
  Creates a `QueueSession` object.

  Specified by:
    `createQueueSession` in interface `XAQueueConnection`
  Overrides:
    `createQueueSession` in class `ActiveMQConnection`
  Parameters:
    `transacted` - indicates whether the session is transacted
    `acknowledgeMode` - indicates whether the consumer or the client will acknowledge any messages it receives; ignored if the session is transacted. Legal values are `Session.AUTO_ACKNOWLEDGE`, `Session.CLIENT_ACKNOWLEDGE`, and `Session.DUPS_OK_ACKNOWLEDGE`.
  Returns:
    a newly created queue session
  Throws:
    `JMSException` - if the `QueueConnection` object fails to create a session due to some internal error or lack of support for the specific transaction and acknowledgement mode.
  See Also:
    `Session.AUTO_ACKNOWLEDGE`, `Session.CLIENT_ACKNOWLEDGE`, `Session.DUPS_OK_ACKNOWLEDGE`

### createTopicSession

    public TopicSession createTopicSession(boolean transacted,
                                           int acknowledgeMode)
                                    throws JMSException

  Description copied from class: `ActiveMQConnection`
  Creates a `TopicSession` object.

  Specified by:
    `createTopicSession` in interface `XATopicConnection`
  Overrides:
    `createTopicSession` in class `ActiveMQConnection`
  Parameters:
    `transacted` - indicates whether the session is transacted
    `acknowledgeMode` - indicates whether the consumer or the client will acknowledge any messages it receives; ignored if the session is transacted. Legal values are `Session.AUTO_ACKNOWLEDGE`, `Session.CLIENT_ACKNOWLEDGE`, and `Session.DUPS_OK_ACKNOWLEDGE`.
  Returns:
    a newly created topic session
  Throws:
    `JMSException` - if the `TopicConnection` object fails to create a session due to some internal error or lack of support for the specific transaction and acknowledgement mode.
  See Also:
    `Session.AUTO_ACKNOWLEDGE`, `Session.CLIENT_ACKNOWLEDGE`, `Session.DUPS_OK_ACKNOWLEDGE`

### createSession

    public Session createSession(boolean transacted,
                                 int acknowledgeMode)
                          throws JMSException

  Description copied from class: `ActiveMQConnection`
  Creates a `Session` object.

  Specified by:
    `createSession` in interface `XAConnection`
  Overrides:
    `createSession` in class `ActiveMQConnection`
  Parameters:
    `transacted` - indicates whether the session is transacted
    `acknowledgeMode` - indicates whether the consumer or the client will acknowledge any messages it receives; ignored if the session is transacted. Legal values are `Session.AUTO_ACKNOWLEDGE`, `Session.CLIENT_ACKNOWLEDGE`, and `Session.DUPS_OK_ACKNOWLEDGE`.
  Returns:
    a newly created session
  Throws:
    `JMSException` - if the `Connection` object fails to create a session due to some internal error or lack of support for the specific transaction and acknowledgement mode.
  See Also:
    `Session.AUTO_ACKNOWLEDGE`, `Session.CLIENT_ACKNOWLEDGE`, `Session.DUPS_OK_ACKNOWLEDGE`

### createXATopicSession

    public XATopicSession createXATopicSession()
                                        throws JMSException

  Specified by:
    `createXATopicSession` in interface `XATopicConnection`
  Throws:
    `JMSException`

### createXAQueueSession

    public XAQueueSession createXAQueueSession()
                                        throws JMSException

  Specified by:
    `createXAQueueSession` in interface `XAQueueConnection`
  Throws:
    `JMSException`

### createActiveMQXASession

    protected ActiveMQXASession createActiveMQXASession()
                                                 throws JMSException

  Throws:
    `JMSException`

### getResourceManagerId

    public String getResourceManagerId()

  Returns:
    Returns the resourceManagerId.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 Protique, Ltd.. All Rights Reserved.