| java.lang.Object org.apache.catalina.startup.ClassLoaderFactory
ClassLoaderFactory | final public class ClassLoaderFactory (Code) | | Utility class for building class loaders for Catalina. The factory
method requires the following parameters in order to build a new class
loader (with suitable defaults in all cases):
- A set of directories containing unpacked classes (and resources)
that should be included in the class loader's
repositories.
- A set of directories containing classes and resources in JAR files.
Each readable JAR file discovered in these directories will be
added to the class loader's repositories.
ClassLoader instance that should become the parent of
the new class loader.
author: Craig R. McClanahan version: $Revision: 467222 $ $Date: 2006-10-24 05:17:11 +0200 (mar., 24 oct. 2006) $ |
Method Summary | |
public static ClassLoader | createClassLoader(File unpacked, File packed, ClassLoader parent) | public static ClassLoader | createClassLoader(File unpacked, File packed, URL urls, ClassLoader parent) | public static ClassLoader | createClassLoader(String locations, Integer types, ClassLoader parent) Create and return a new class loader, based on the configuration
defaults and the specified directory paths:
Parameters: locations - Array of strings containing class directories, jar files,jar directories or URLS that should be added to the repositories ofthe class loader. |
createClassLoader | public static ClassLoader createClassLoader(File unpacked, File packed, ClassLoader parent) throws Exception(Code) | | Create and return a new class loader, based on the configuration
defaults and the specified directory paths:
Parameters: unpacked - Array of pathnames to unpacked directories that shouldbe added to the repositories of the class loader, or null for no unpacked directories to be considered Parameters: packed - Array of pathnames to directories containing JAR filesthat should be added to the repositories of the class loader, or null for no directories of JAR files to be considered Parameters: parent - Parent class loader for the new class loader, ornull for the system class loader. exception: Exception - if an error occurs constructing the class loader |
createClassLoader | public static ClassLoader createClassLoader(File unpacked, File packed, URL urls, ClassLoader parent) throws Exception(Code) | | Create and return a new class loader, based on the configuration
defaults and the specified directory paths:
Parameters: unpacked - Array of pathnames to unpacked directories that shouldbe added to the repositories of the class loader, or null for no unpacked directories to be considered Parameters: packed - Array of pathnames to directories containing JAR filesthat should be added to the repositories of the class loader, or null for no directories of JAR files to be considered Parameters: urls - Array of URLs to remote repositories, designing either JAR resources or uncompressed directories that should be added to the repositories of the class loader, or null for no directories of JAR files to be considered Parameters: parent - Parent class loader for the new class loader, ornull for the system class loader. exception: Exception - if an error occurs constructing the class loader |
createClassLoader | public static ClassLoader createClassLoader(String locations, Integer types, ClassLoader parent) throws Exception(Code) | | Create and return a new class loader, based on the configuration
defaults and the specified directory paths:
Parameters: locations - Array of strings containing class directories, jar files,jar directories or URLS that should be added to the repositories ofthe class loader. The type is given by the member of param types. Parameters: types - Array of types for the members of param locations.Possible values are IS_DIR (class directory), IS_JAR (single jar file),IS_GLOB (directory of jar files) and IS_URL (URL). Parameters: parent - Parent class loader for the new class loader, ornull for the system class loader. exception: Exception - if an error occurs constructing the class loader |
|
|