| java.lang.Object org.apache.catalina.valves.ValveBase org.apache.catalina.core.StandardHostValve
StandardHostValve | final class StandardHostValve extends ValveBase (Code) | | Valve that implements the default basic behavior for the
StandardHost container implementation.
USAGE CONSTRAINT: This implementation is likely to be useful only
when processing HTTP requests.
author: Craig R. McClanahan author: Remy Maucherat version: $Revision: 1.19 $ $Date: 2004/05/26 15:41:14 $ |
Method Summary | |
protected boolean | custom(Request request, Response response, ErrorPage errorPage) Handle an HTTP status code or Java exception by forwarding control
to the location included in the specified errorPage object. | protected static ErrorPage | findErrorPage(Context context, Throwable exception) Find and return the ErrorPage instance for the specified exception's
class, or an ErrorPage instance for the closest superclass for which
there is such a definition. | public String | getInfo() Return descriptive information about this Valve implementation. | final public void | invoke(Request request, Response response, ValveContext valveContext) Select the appropriate child Context to process this request,
based on the specified request URI. | protected void | log(String message) Log a message on the Logger associated with our Container (if any). | protected void | log(String message, Throwable throwable) Log a message on the Logger associated with our Container (if any). | protected void | status(Request request, Response response) Handle the HTTP status code (and corresponding message) generated
while processing the specified Request to produce the specified
Response. | protected void | throwable(Request request, Response response, Throwable throwable) Handle the specified Throwable encountered while processing
the specified Request to produce the specified Response. |
custom | protected boolean custom(Request request, Response response, ErrorPage errorPage)(Code) | | Handle an HTTP status code or Java exception by forwarding control
to the location included in the specified errorPage object. It is
assumed that the caller has already recorded any request attributes
that are to be forwarded to this page. Return true if
we successfully utilized the specified error page location, or
false if the default error report should be rendered.
Parameters: request - The request being processed Parameters: response - The response being generated Parameters: errorPage - The errorPage directive we are obeying |
findErrorPage | protected static ErrorPage findErrorPage(Context context, Throwable exception)(Code) | | Find and return the ErrorPage instance for the specified exception's
class, or an ErrorPage instance for the closest superclass for which
there is such a definition. If no associated ErrorPage instance is
found, return null .
Parameters: context - The Context in which to search Parameters: exception - The exception for which to find an ErrorPage |
getInfo | public String getInfo()(Code) | | Return descriptive information about this Valve implementation.
|
invoke | final public void invoke(Request request, Response response, ValveContext valveContext) throws IOException, ServletException(Code) | | Select the appropriate child Context to process this request,
based on the specified request URI. If no matching Context can
be found, return an appropriate HTTP error.
Parameters: request - Request to be processed Parameters: response - Response to be produced Parameters: valveContext - Valve context used to forward to the next Valve exception: IOException - if an input/output error occurred exception: ServletException - if a servlet error occurred |
log | protected void log(String message)(Code) | | Log a message on the Logger associated with our Container (if any).
Parameters: message - Message to be logged |
log | protected void log(String message, Throwable throwable)(Code) | | Log a message on the Logger associated with our Container (if any).
Parameters: message - Message to be logged Parameters: throwable - Associated exception |
status | protected void status(Request request, Response response)(Code) | | Handle the HTTP status code (and corresponding message) generated
while processing the specified Request to produce the specified
Response. Any exceptions that occur during generation of the error
report are logged and swallowed.
Parameters: request - The request being processed Parameters: response - The response being generated |
throwable | protected void throwable(Request request, Response response, Throwable throwable)(Code) | | Handle the specified Throwable encountered while processing
the specified Request to produce the specified Response. Any
exceptions that occur during generation of the exception report are
logged and swallowed.
Parameters: request - The request being processed Parameters: response - The response being generated Parameters: throwable - The exception that occurred (which possibly wrapsa root cause exception |
|
|