public class ClassResolver extends Object
resolveClass(java.lang.String, java.lang.ClassLoader)method should be used to load all user-supplied classes, and the
ClassResolver.Streamclass should be used as a replacement for ObjectInputStream to deserialize instances of user-supplied classes.
The ClassLoader specified as a param should be the one configured using EnvironmentConfig.setClassLoader. This loader is used, if non-null. If the loader param is null, but a non-null thread-context loader is available, the latter is used. If the loader param and thread-context loader are both null, or if they fail to load a class by throwing ClassNotFoundException, then the default Java mechanisms for determining the class loader are used.
|Modifier and Type||Class and Description|
A specialized ObjectInputStream that supports use of a user-specified ClassLoader.
|Constructor and Description|
|Modifier and Type||Method and Description|
A specialized Class.forName method that supports use of a user-specified ClassLoader.
public static Class resolveClass(String className, ClassLoader classLoader) throws ClassNotFoundException
Copyright (c) 2004, 2014 Oracle and/or its affiliates. All rights reserved.