| java.lang.Object org.xins.common.servlet.container.ServletClassLoader
ServletClassLoader | public class ServletClassLoader (Code) | | Class used to get the Servlet Class loader.
The class loader returned is a child first class loader.
version: $Revision: 1.19 $ $Date: 2007/09/18 08:45:08 $ author: Anthony Goubard |
Field Summary | |
final public static int | USE_CLASSPATH_LIB Load the Servlet code from the WAR file and use the current
classpath for the libraries. | final public static int | USE_CURRENT_CLASSPATH Use the current class loader to load the servlet and the libraries. | final public static int | USE_WAR_EXTERNAL_LIB Load the servlet code and the standard libraries from the CLASSPATH. | final public static int | USE_WAR_LIB Load the servlet code and the libraries from the WAR file. | final public static int | USE_XINS_LIB Load the servlet code from the WAR file and try to find the libraries
in the same directory as this xins-common.jar and <:parent>/lib
directory. |
Method Summary | |
public static ClassLoader | getServletClassLoader(File warFile, int mode) Gest the class loader that will loader the servlet.
Parameters: warFile - the WAR file containing the Servlet. Parameters: mode - the mode in which the servlet should be loaded. |
USE_CLASSPATH_LIB | final public static int USE_CLASSPATH_LIB(Code) | | Load the Servlet code from the WAR file and use the current
classpath for the libraries.
|
USE_CURRENT_CLASSPATH | final public static int USE_CURRENT_CLASSPATH(Code) | | Use the current class loader to load the servlet and the libraries.
|
USE_WAR_EXTERNAL_LIB | final public static int USE_WAR_EXTERNAL_LIB(Code) | | Load the servlet code and the standard libraries from the CLASSPATH.
Load the included external libraries from the WAR file.
|
USE_WAR_LIB | final public static int USE_WAR_LIB(Code) | | Load the servlet code and the libraries from the WAR file.
This may take some time as the libraries need to be extracted from the
WAR file.
|
USE_XINS_LIB | final public static int USE_XINS_LIB(Code) | | Load the servlet code from the WAR file and try to find the libraries
in the same directory as this xins-common.jar and <:parent>/lib
directory.
|
getServletClassLoader | public static ClassLoader getServletClassLoader(File warFile, int mode) throws IOException(Code) | | Gest the class loader that will loader the servlet.
Parameters: warFile - the WAR file containing the Servlet. Parameters: mode - the mode in which the servlet should be loaded. The possible values areUSE_CURRENT_CLASSPATH , USE_CLASSPATH_LIB ,USE_XINS_LIB , USE_WAR_LIB ,USE_WAR_EXTERNAL_LIB .the Class loader to use to load the Servlet. throws: IOException - if the file cannot be read or is incorrect. |
|
|