Package com.mchange.v2.naming
Class ReferenceableUtils
- java.lang.Object
-
- com.mchange.v2.naming.ReferenceableUtils
-
public final class ReferenceableUtils extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classReferenceableUtils.ExtractRecDeprecated.nesting references seemed useful until I realized that references are Serializable and can be stored in a BinaryRefAddr.
-
Field Summary
Fields Modifier and Type Field Description static java.util.SetALL_FACTORY_CLASS_NAMES
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static booleanacceptDeserializedInitialContextEnvironment(PropertiesConfig pcfg)static voidappendToReference(javax.naming.Reference appendTo, javax.naming.Reference orig)Deprecated.nesting references seemed useful until I realized that references are Serializable and can be stored in a BinaryRefAddr.static voidassertAcceptableName(java.lang.Object jndiName, PropertiesConfig pcfg)static ReferenceableUtils.ExtractRecextractNestedReference(javax.naming.Reference extractFrom, int index)Deprecated.nesting references seemed useful until I realized that references are Serializable and can be stored in a BinaryRefAddr.static java.lang.StringliteralNullToNull(java.lang.String s)A null string value in a Reference sometimes goes to the literal "null".static java.lang.ObjectreferenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env)static java.lang.ObjectreferenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env, PropertiesConfig pcfg)static java.lang.ObjectreferenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env, java.util.Set allowedFactoryClassNames)The allowedFactoryClassNames whitelist test can be (but generally should not be) circumvented by explicitly providing ReferenceUtils.ALL_FACTORY_CLASS_NAMES as the argument allowedFactoryClassNames.static java.lang.ObjectreferenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env, java.util.Set allowedFactoryClassNames, PropertiesConfig pcfg)The allowedFactoryClassNames whitelist test can be (but generally should not be) circumvented by explicitly providing ReferenceUtils.ALL_FACTORY_CLASS_NAMES as the argument allowedFactoryClassNames.static booleansupportReferenceRemoteFactoryClassLocation(PropertiesConfig pcfg)
-
-
-
Method Detail
-
literalNullToNull
public static java.lang.String literalNullToNull(java.lang.String s)
A null string value in a Reference sometimes goes to the literal "null". Sigh. We convert this string to a Java null.
-
referenceToObject
public static java.lang.Object referenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env) throws javax.naming.NamingException- Throws:
javax.naming.NamingException
-
referenceToObject
public static java.lang.Object referenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env, PropertiesConfig pcfg) throws javax.naming.NamingException- Throws:
javax.naming.NamingException
-
referenceToObject
public static java.lang.Object referenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env, java.util.Set allowedFactoryClassNames) throws javax.naming.NamingExceptionThe allowedFactoryClassNames whitelist test can be (but generally should not be) circumvented by explicitly providing ReferenceUtils.ALL_FACTORY_CLASS_NAMES as the argument allowedFactoryClassNames. allowedFactoryClassNames must not be null. (A NullPointerException will be provoked if it is.)- Throws:
javax.naming.NamingException
-
referenceToObject
public static java.lang.Object referenceToObject(javax.naming.Reference ref, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable env, java.util.Set allowedFactoryClassNames, PropertiesConfig pcfg) throws javax.naming.NamingExceptionThe allowedFactoryClassNames whitelist test can be (but generally should not be) circumvented by explicitly providing ReferenceUtils.ALL_FACTORY_CLASS_NAMES as the argument allowedFactoryClassNames. allowedFactoryClassNames must not be null. (A NullPointerException will be provoked if it is.)- Throws:
javax.naming.NamingException
-
assertAcceptableName
public static void assertAcceptableName(java.lang.Object jndiName, PropertiesConfig pcfg) throws javax.naming.NamingException- Throws:
javax.naming.NamingException
-
supportReferenceRemoteFactoryClassLocation
public static boolean supportReferenceRemoteFactoryClassLocation(PropertiesConfig pcfg)
-
acceptDeserializedInitialContextEnvironment
public static boolean acceptDeserializedInitialContextEnvironment(PropertiesConfig pcfg)
-
appendToReference
public static void appendToReference(javax.naming.Reference appendTo, javax.naming.Reference orig) throws javax.naming.NamingExceptionDeprecated.nesting references seemed useful until I realized that references are Serializable and can be stored in a BinaryRefAddr. Oops.- Throws:
javax.naming.NamingException
-
extractNestedReference
public static ReferenceableUtils.ExtractRec extractNestedReference(javax.naming.Reference extractFrom, int index) throws javax.naming.NamingException
Deprecated.nesting references seemed useful until I realized that references are Serializable and can be stored in a BinaryRefAddr. Oops.- Throws:
javax.naming.NamingException
-
-