public class JndiVariableResolver extends java.lang.Object implements VariableResolver
Constructor and Description |
---|
JndiVariableResolver() |
JndiVariableResolver(java.lang.String prepend,
java.lang.String mapping)
This constructor take arguments to initialize JNDI names.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
int |
hashCode() |
java.lang.Object |
resolveVariable(java.lang.String var)
Get object from JNDI binding
|
public JndiVariableResolver(java.lang.String prepend, java.lang.String mapping)
For example:
By default, session beans will bind to JNDI in the form ejbName/remote for remote interfaces and ejbName/local in the case of local interfaces. When the EJBs are deployed in an .ear file, the default jndi binding will be prepended by the name of the .ear file. As a result, if the ear file name is foo.ear, prepend is: foo
If you define your own jndi binding, the string should be in key-value pairs format as "a=custom/MySession,b=custom/MySession2,emf=java:/EntityManagerFactory"
prepend
- prepended part of JNDI namemapping
- key-value pairs for JNDI name and its corresponding variable namepublic JndiVariableResolver()
public java.lang.Object resolveVariable(java.lang.String var) throws XelException
resolveVariable
in interface VariableResolver
var
- JNDI binding nameXelException
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Copyright © 2005-2021 Potix Corporation. All Rights Reserved.