org.apache.cocoon.servlet
Class BootstrapServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
org.apache.cocoon.servlet.ParanoidCocoonServlet
org.apache.cocoon.servlet.BootstrapServlet
- All Implemented Interfaces:
- Serializable, Servlet, ServletConfig
public class BootstrapServlet
- extends ParanoidCocoonServlet
A bootstrap servlet to allow Cocoon to run in servlet engines that aren't fully
compliant with the servlet 2.2 spec.
This servlet adds a mandatory "context-dir" parameter to those accepted by CocoonServlet
,
which should point to Cocoon's context directory (e.g. "/path-to-webapp/cocoon
").
This directory is used to :
- build a classloader with the correct class path with the contents of
WEB-INF/classes
and WEB-INF/lib
(see
ParanoidClassLoader
),
- resolve paths for context resources.
- Version:
- CVS $Id: BootstrapServlet.html 1304258 2012-03-23 10:09:27Z ilgrosso $
- Author:
- Sylvain Wallez
- See Also:
- Serialized Form
Method Summary |
protected File |
getContextDir()
Get the web application context directory. |
protected void |
initServlet()
Initialize the wrapped servlet. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
contextDir
protected File contextDir
BootstrapServlet
public BootstrapServlet()
getContextDir
protected File getContextDir()
throws ServletException
- Description copied from class:
ParanoidCocoonServlet
- Get the web application context directory.
- Overrides:
getContextDir
in class ParanoidCocoonServlet
- Returns:
- the context dir
- Throws:
ServletException
initServlet
protected void initServlet()
throws ServletException
- Description copied from class:
ParanoidCocoonServlet
- Initialize the wrapped servlet. Subclasses (see
BootstrapServlet
change the ServletConfig
given to the servlet.
- Overrides:
initServlet
in class ParanoidCocoonServlet
- Throws:
ServletException
Copyright © 1999-2010 The Apache Software Foundation. All Rights Reserved.