Class JNDIUtil
- java.lang.Object
-
- org.apache.activemq.artemis.utils.JNDIUtil
-
public class JNDIUtil extends Object
-
-
Constructor Summary
Constructors Constructor Description JNDIUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ContextcreateContext(Context c, String path)Create a context path recursively.static voidrebind(Context c, String jndiName, Object o)Context.rebind() requires that all intermediate contexts and the target context (that named by all but terminal atomic component of the name) must already exist, otherwise NameNotFoundException is thrown.static voidtearDownRecursively(Context c)
-
-
-
Method Detail
-
createContext
public static Context createContext(Context c, String path) throws NamingException
Create a context path recursively.- Throws:
NamingException
-
tearDownRecursively
public static void tearDownRecursively(Context c) throws Exception
- Throws:
Exception
-
rebind
public static void rebind(Context c, String jndiName, Object o) throws NamingException
Context.rebind() requires that all intermediate contexts and the target context (that named by all but terminal atomic component of the name) must already exist, otherwise NameNotFoundException is thrown. This method behaves similar to Context.rebind(), but creates intermediate contexts, if necessary.- Throws:
NamingException
-
-