SingleConnectionFactory
@Deprecated public class SingleConnectionFactory102 extends SingleConnectionFactory
SingleConnectionFactory
for the JMS 1.0.2 specification,
not relying on JMS 1.1 methods like SingleConnectionFactory itself.
This class can be used for JMS 1.0.2 providers, offering the same API as
SingleConnectionFactory does for JMS 1.1 providers.
You need to set the "pubSubDomain" property
,
since this class will always explicitly differentiate between a
QueueConnection
and a TopicConnection
.
SingleConnectionFactory.setTargetConnectionFactory(javax.jms.ConnectionFactory)
,
setPubSubDomain(boolean)
logger
Constructor and Description |
---|
SingleConnectionFactory102()
Deprecated.
Create a new SingleConnectionFactory102 for bean-style usage.
|
SingleConnectionFactory102(ConnectionFactory connectionFactory,
boolean pubSubDomain)
Deprecated.
Create a new SingleConnectionFactory102 that always returns a single
Connection that it will lazily create via the given target
ConnectionFactory.
|
Modifier and Type | Method and Description |
---|---|
void |
afterPropertiesSet()
Deprecated.
In addition to checking whether the target ConnectionFactory is set,
make sure that the supplied factory is of the appropriate type for
the specified destination type: QueueConnectionFactory for queues,
TopicConnectionFactory for topics.
|
protected Connection |
doCreateConnection()
Deprecated.
This implementation overrides the superclass method to use JMS 1.0.2 API.
|
boolean |
isPubSubDomain()
Deprecated.
Return whether the Publish/Subscribe domain (Topics) is used.
|
void |
setPubSubDomain(boolean pubSubDomain)
Deprecated.
Configure the factory with knowledge of the JMS domain used.
|
closeConnection, createConnection, createConnection, createQueueConnection, createQueueConnection, createSession, createTopicConnection, createTopicConnection, destroy, getClientId, getExceptionListener, getSession, getSharedConnectionProxy, getTargetConnectionFactory, initConnection, isReconnectOnException, onException, prepareConnection, resetConnection, setClientId, setExceptionListener, setReconnectOnException, setTargetConnectionFactory
public SingleConnectionFactory102()
public SingleConnectionFactory102(ConnectionFactory connectionFactory, boolean pubSubDomain)
connectionFactory
- the target ConnectionFactorypubSubDomain
- whether the Publish/Subscribe domain (Topics) or
Point-to-Point domain (Queues) should be usedpublic void setPubSubDomain(boolean pubSubDomain)
Default is Point-to-Point (Queues).
pubSubDomain
- true
for Publish/Subscribe domain (Topics),
false
for Point-to-Point domain (Queues)public boolean isPubSubDomain()
public void afterPropertiesSet()
afterPropertiesSet
in interface InitializingBean
afterPropertiesSet
in class SingleConnectionFactory
protected Connection doCreateConnection() throws JMSException
doCreateConnection
in class SingleConnectionFactory
JMSException
- if thrown by JMS API methods