Package com.sun.corba.ee.impl.util
Class JDKBridge
java.lang.Object
com.sun.corba.ee.impl.util.JDKBridge
Utility methods for doing various method calls which are used
by multiple classes
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String
private static String
private static Logger
private static final String
private static boolean
private static final ORBUtilSystemException
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic String
Get local codebase System property (java.rmi.server.codebase).static Class
Returns a class instance for the specified class.static Class
Returns a class instance for the specified class.static Class
loadClass
(String className, String remoteCodebase, ClassLoader loader) Returns a class instance for the specified class.private static Class
loadClassM
(String className, String remoteCodebase, boolean useCodebaseOnly) static void
Set the codebase and useCodebaseOnly properties.static void
setLocalCodebase
(String codebase) Set the default code base.static boolean
Return true if the system property "java.rmi.server.useCodebaseOnly" is set, false otherwise.
-
Field Details
-
wrapper
-
logger
-
LOCAL_CODEBASE_KEY
- See Also:
-
USE_CODEBASE_ONLY_KEY
- See Also:
-
localCodebase
-
useCodebaseOnly
private static boolean useCodebaseOnly
-
-
Constructor Details
-
JDKBridge
public JDKBridge()
-
-
Method Details
-
getLocalCodebase
Get local codebase System property (java.rmi.server.codebase). May be null or a space separated array of URLS.- Returns:
- The value of the property
-
useCodebaseOnly
public static boolean useCodebaseOnly()Return true if the system property "java.rmi.server.useCodebaseOnly" is set, false otherwise.- Returns:
- If the property is set
-
loadClass
public static Class loadClass(String className, String remoteCodebase, ClassLoader loader) throws ClassNotFoundException Returns a class instance for the specified class.- Parameters:
className
- the name of the classremoteCodebase
- a space-separated array of urls at which the class might be found. May be null.loader
- a ClassLoader who may be used to load the class if all other methods fail.- Returns:
- the
Class
object representing the loaded class. - Throws:
ClassNotFoundException
- if class cannot be loaded.
-
loadClass
public static Class loadClass(String className, String remoteCodebase) throws ClassNotFoundException Returns a class instance for the specified class.- Parameters:
className
- the name of the classremoteCodebase
- a space-separated array of urls at which the class might be found. May be null.- Returns:
- the
Class
object representing the loaded class. - Throws:
ClassNotFoundException
- if class cannot be loaded.
-
loadClass
Returns a class instance for the specified class.- Parameters:
className
- the name of the class- Returns:
- the
Class
object representing the loaded class. - Throws:
ClassNotFoundException
- if class cannot be loaded.
-
setCodebaseProperties
public static void setCodebaseProperties()Set the codebase and useCodebaseOnly properties. This is public only for test code. -
setLocalCodebase
Set the default code base. This method is here only for test code.- Parameters:
codebase
- The local codebase
-
loadClassM
private static Class loadClassM(String className, String remoteCodebase, boolean useCodebaseOnly) throws ClassNotFoundException - Throws:
ClassNotFoundException
-