public class PooledConnection extends Object implements javax.jms.Connection
Modifier and Type | Field and Description |
---|---|
(package private) Connection |
delegate
The underlying connection to Joram's server
|
(package private) String |
name
The identity of the authentified user for this connection
|
(package private) String |
password
The identity of the authentified user for this connection
|
(package private) PooledConnectionFactory |
pcf
The pooled ConnectionFactory
|
Constructor and Description |
---|
PooledConnection(PooledConnectionFactory pcf,
String name,
String password)
Creates a new pooled connection.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close the pooled connection, depending of the pool state this can results
in the real closing of the connection of the inserting in the pool of idle
connections.
|
javax.jms.ConnectionConsumer |
createConnectionConsumer(javax.jms.Destination dest,
String selector,
javax.jms.ServerSessionPool sessionPool,
int maxMessages) |
javax.jms.ConnectionConsumer |
createDurableConnectionConsumer(javax.jms.Topic topic,
String subName,
String selector,
javax.jms.ServerSessionPool sessPool,
int maxMessages) |
javax.jms.Session |
createSession() |
javax.jms.Session |
createSession(boolean transacted,
int acknowledgeMode) |
javax.jms.Session |
createSession(int sessionMode) |
javax.jms.ConnectionConsumer |
createSharedConnectionConsumer(javax.jms.Topic topic,
String subscriptionName,
String messageSelector,
javax.jms.ServerSessionPool sessionPool,
int maxMessages) |
javax.jms.ConnectionConsumer |
createSharedDurableConnectionConsumer(javax.jms.Topic topic,
String subscriptionName,
String messageSelector,
javax.jms.ServerSessionPool sessionPool,
int maxMessages) |
String |
getClientID() |
javax.jms.ExceptionListener |
getExceptionListener() |
javax.jms.ConnectionMetaData |
getMetaData() |
void |
setClientID(String clientID) |
void |
setExceptionListener(javax.jms.ExceptionListener listener) |
void |
start() |
void |
stop() |
String |
toString() |
PooledConnectionFactory pcf
Connection delegate
String name
String password
public PooledConnection(PooledConnectionFactory pcf, String name, String password) throws javax.jms.JMSException
pcf
- The pooled ConnectionFactory.name
- The name of the authentified user for this connection.password
- The password of the authentified user for this connection.javax.jms.JMSException
- An error occurs during the connection.public void close() throws javax.jms.JMSException
close
in interface AutoCloseable
close
in interface javax.jms.Connection
javax.jms.JMSException
Connection.close()
public javax.jms.ConnectionConsumer createConnectionConsumer(javax.jms.Destination dest, String selector, javax.jms.ServerSessionPool sessionPool, int maxMessages) throws javax.jms.JMSException
createConnectionConsumer
in interface javax.jms.Connection
javax.jms.JMSException
Connection.createConnectionConsumer(javax.jms.Destination, java.lang.String, javax.jms.ServerSessionPool, int)
public javax.jms.ConnectionConsumer createDurableConnectionConsumer(javax.jms.Topic topic, String subName, String selector, javax.jms.ServerSessionPool sessPool, int maxMessages) throws javax.jms.JMSException
createDurableConnectionConsumer
in interface javax.jms.Connection
javax.jms.JMSException
Connection.createDurableConnectionConsumer(javax.jms.Topic, java.lang.String, java.lang.String, javax.jms.ServerSessionPool, int)
public javax.jms.Session createSession(boolean transacted, int acknowledgeMode) throws javax.jms.JMSException
createSession
in interface javax.jms.Connection
javax.jms.JMSException
Connection.createSession(boolean, int)
public String getClientID() throws javax.jms.JMSException
getClientID
in interface javax.jms.Connection
javax.jms.JMSException
Connection.getClientID()
public javax.jms.ExceptionListener getExceptionListener() throws javax.jms.JMSException
getExceptionListener
in interface javax.jms.Connection
javax.jms.JMSException
Connection.getExceptionListener()
public javax.jms.ConnectionMetaData getMetaData() throws javax.jms.JMSException
getMetaData
in interface javax.jms.Connection
javax.jms.JMSException
Connection.getMetaData()
public void setClientID(String clientID) throws javax.jms.JMSException
setClientID
in interface javax.jms.Connection
javax.jms.JMSException
Connection.setClientID(java.lang.String)
public void setExceptionListener(javax.jms.ExceptionListener listener) throws javax.jms.JMSException
setExceptionListener
in interface javax.jms.Connection
javax.jms.JMSException
Connection.setExceptionListener(javax.jms.ExceptionListener)
public void start() throws javax.jms.JMSException
start
in interface javax.jms.Connection
javax.jms.JMSException
Connection.start()
public void stop() throws javax.jms.JMSException
stop
in interface javax.jms.Connection
javax.jms.JMSException
Connection.stop()
public String toString()
toString
in class Object
Object.toString()
public javax.jms.Session createSession(int sessionMode) throws javax.jms.JMSException
createSession
in interface javax.jms.Connection
javax.jms.JMSException
public javax.jms.Session createSession() throws javax.jms.JMSException
createSession
in interface javax.jms.Connection
javax.jms.JMSException
public javax.jms.ConnectionConsumer createSharedConnectionConsumer(javax.jms.Topic topic, String subscriptionName, String messageSelector, javax.jms.ServerSessionPool sessionPool, int maxMessages) throws javax.jms.JMSException
createSharedConnectionConsumer
in interface javax.jms.Connection
javax.jms.JMSException
public javax.jms.ConnectionConsumer createSharedDurableConnectionConsumer(javax.jms.Topic topic, String subscriptionName, String messageSelector, javax.jms.ServerSessionPool sessionPool, int maxMessages) throws javax.jms.JMSException
createSharedDurableConnectionConsumer
in interface javax.jms.Connection
javax.jms.JMSException
Copyright © 2018 ScalAgent D.T.. All Rights Reserved.