|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.tomcat.core.BaseInterceptor
org.apache.tomcat.modules.mappers.SimpleMapper1
This class will set up the data structures used by a simple patern matching algorithm and use it to extract the path components from the request URI. This particular implementation does the following: - extract the information that is relevant to matching from the Request object. The current implementation deals with the Host header and the request URI. - Use an external mapper to find the best match. - Adjust the request paths SimpleMapper1 will set 2 context notes - "map.extensions" is a SimpleHashtable containing the extension mappings, and "tomcat.map.default" for the default map, if defined explicitely. It will also maintain a global mapping structure for all prefix mappings, including contexts. The execution time is proportional with the number of hosts, number of context, number of mappings and with the length of the request.
Field Summary |
Fields inherited from class org.apache.tomcat.core.BaseInterceptor |
ct, ctx, debug, DECLINED, loghelper, OK |
Constructor Summary | |
SimpleMapper1()
|
Method Summary | |
void |
addContainer(Container ct)
Associate URL pattern to a set of propreties. |
void |
addContext(ContextManager cm,
Context ctx)
Called when a context is added. |
int |
contextMap(Request req)
First step of request processing is finding the Context. |
void |
engineInit(ContextManager cm)
Set the context manager. |
void |
removeContainer(Container ct)
A rule was removed, update the internal strucures. |
void |
removeContext(ContextManager cm,
Context ctx)
Called when a context is removed from a CM - we must ask the mapper to remove all the maps related with this context |
void |
setIgnoreCase(boolean b)
Use case insensitive match, for windows and similar platforms |
void |
setMapCache(boolean v)
Allow the mapper to cache mapping results - resulting in a faster match for frequent requests. |
Methods inherited from class org.apache.tomcat.core.BaseInterceptor |
addHandler, addInterceptor, addSecurityConstraint, afterBody, authenticate, authorize, beforeBody, beforeCommit, contextInit, contextShutdown, contextState, copyContext, engineShutdown, engineStart, engineState, engineStop, findSession, getContext, getContextManager, getDebug, getInfo, getLog, getNote, getNote, handleError, log, log, log, log, postInitCheck, postReadRequest, postRequest, postService, postServletDestroy, postServletInit, preInitCheck, preService, preServletDestroy, preServletInit, registerHooks, reload, removeHandler, removeInterceptor, requestMap, sessionState, setContext, setContextManager, setDebug, setInfo, setNote, setNote |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public SimpleMapper1()
Method Detail |
public void setMapCache(boolean v)
public void setIgnoreCase(boolean b)
public void engineInit(ContextManager cm) throws TomcatException
engineInit
in class BaseInterceptor
TomcatException
- The module will not be added if any
exception is thrown by engineInit.public void addContext(ContextManager cm, Context ctx) throws TomcatException
addContext
in class BaseInterceptor
TomcatException
public void removeContext(ContextManager cm, Context ctx) throws TomcatException
removeContext
in class BaseInterceptor
TomcatException
public void addContainer(Container ct) throws TomcatException
addContainer
in class BaseInterceptor
TomcatException
public void removeContainer(Container ct) throws TomcatException
BaseInterceptor
removeContainer
in class BaseInterceptor
TomcatException
public int contextMap(Request req)
contextMap
in class BaseInterceptor
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |