public class JndiXAConnectionFactory extends Object implements javax.jms.XAConnectionFactory
XAConnectionFactory implementation that wraps another XAConnectionFactory implementation available
in some JNDI tree.| Constructor and Description |
|---|
JndiXAConnectionFactory() |
| Modifier and Type | Method and Description |
|---|---|
javax.jms.XAConnection |
createXAConnection() |
javax.jms.XAConnection |
createXAConnection(String userName,
String password) |
Properties |
getExtraJndiProperties()
The extra JNDI environment properties added the the
InitialContext's environment upon creation. |
String |
getInitialContextFactory()
|
String |
getName()
The JNDI name under which the
XAConnectionFactory is available. |
String |
getProviderUrl()
|
String |
getSecurityCredentials()
|
String |
getSecurityPrincipal()
|
String |
getUrlPkgPrefixes()
|
protected void |
init() |
boolean |
isNarrowJndiObject()
Should
PortableRemoteObject.narrow(Object, Class) be applied on the object looked up from
JNDI before trying to cast it to XAConnectionFactory ? |
void |
setExtraJndiProperties(Properties extraJndiProperties)
Set the extra JNDI environment properties added the the
InitialContext's environment upon creation. |
void |
setInitialContextFactory(String initialContextFactory)
|
void |
setName(String name)
Set the JNDI name under which the
XAConnectionFactory is available. |
void |
setNarrowJndiObject(boolean narrowJndiObject)
Set if
PortableRemoteObject.narrow(Object, Class) should be applied on the object looked up from
JNDI before trying to cast it to XAConnectionFactory ? |
void |
setProviderUrl(String providerUrl)
|
void |
setSecurityCredentials(String securityCredentials)
|
void |
setSecurityPrincipal(String securityPrincipal)
|
void |
setUrlPkgPrefixes(String urlPkgPrefixes)
|
public String getInitialContextFactory()
Context.INITIAL_CONTEXT_FACTORY value.public void setInitialContextFactory(String initialContextFactory)
Context.INITIAL_CONTEXT_FACTORY of the JNDI Context used to fetch the XAConnectionFactory.
If not set, the Context is created without the environment parameter, using the default constructor. This means
all other properties (providerUrl, urlPkgPrefixes, extraJndiProperties...) are then ignored.initialContextFactory - the Context.INITIAL_CONTEXT_FACTORY value.public String getProviderUrl()
Context.PROVIDER_URL value.public void setProviderUrl(String providerUrl)
providerUrl - the Context.PROVIDER_URL value.public String getUrlPkgPrefixes()
Context.URL_PKG_PREFIXES value.public void setUrlPkgPrefixes(String urlPkgPrefixes)
urlPkgPrefixes - the Context.URL_PKG_PREFIXES value.public String getSecurityPrincipal()
Context.SECURITY_PRINCIPAL value.public void setSecurityPrincipal(String securityPrincipal)
Context.SECURITY_PRINCIPAL of the JNDI Context used to fetch the XAConnectionFactory.
If Context.INITIAL_CONTEXT_FACTORY and Context.PROVIDER_URL are not set, this value is ignored.securityPrincipal - the Context.SECURITY_PRINCIPAL value.public String getSecurityCredentials()
Context.SECURITY_CREDENTIALS value.public void setSecurityCredentials(String securityCredentials)
Context.SECURITY_CREDENTIALS of the JNDI Context used to fetch the XAConnectionFactory.
If Context.INITIAL_CONTEXT_FACTORY and Context.PROVIDER_URL are not set, this value is ignored.securityCredentials - the Context.SECURITY_CREDENTIALS value.public String getName()
XAConnectionFactory is available.public void setName(String name)
XAConnectionFactory is available.name - the JNDI name.public Properties getExtraJndiProperties()
InitialContext's environment upon creation.public void setExtraJndiProperties(Properties extraJndiProperties)
InitialContext's environment upon creation.extraJndiProperties - The extra JNDI environment properties.public boolean isNarrowJndiObject()
PortableRemoteObject.narrow(Object, Class) be applied on the object looked up from
JNDI before trying to cast it to XAConnectionFactory ?public void setNarrowJndiObject(boolean narrowJndiObject)
PortableRemoteObject.narrow(Object, Class) should be applied on the object looked up from
JNDI before trying to cast it to XAConnectionFactory ?narrowJndiObject - true if the object should be narrowed, false otherwise.protected void init()
throws NamingException
NamingExceptionpublic javax.jms.XAConnection createXAConnection()
throws javax.jms.JMSException
createXAConnection in interface javax.jms.XAConnectionFactoryjavax.jms.JMSExceptionCopyright © 2006-2016 Bitronix Software. All Rights Reserved.