Overview Package Class Tree Deprecated Help PREV CLASS NEXT CLASS FRAMES NO FRAMES SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD
org.apache.coyote.tomcat5
Class CoyoteAdapterjava.lang.Object org.apache.coyote.tomcat5.CoyoteAdapter
- All Implemented Interfaces:
- Adapter
- public class CoyoteAdapter
- extends java.lang.Object
- implements Adapter
Implementation of a request processor which delegates the processing to a Coyote processor.
- Version:
- $Revision: 1.26 $ $Date: 2004/05/14 11:00:25 $
- Author:
- Craig R. McClanahan, Remy Maucherat
Field Summary static int ADAPTER_NOTES
protected StringManager sm
The string manager for this package.
Constructor Summary CoyoteAdapter(CoyoteConnector connector)
Construct a new CoyoteProcessor associated with the specified connector.
Method Summary protected void convertURI(MessageBytes uri, CoyoteRequest request)
Character conversion of the URI.protected static void copyBytes(byte[] b, int dest, int src, int len)
Copy an array of bytes to a different position.protected void log(java.lang.String message)
Log a message on the Logger associated with our Container (if any)protected void log(java.lang.String message, java.lang.Throwable throwable)
Log a message on the Logger associated with our Container (if any)static boolean normalize(MessageBytes uriMB)
Normalize URI.protected void parseSessionCookiesId(Request req, CoyoteRequest request)
Parse session id in URL.protected void parseSessionId(Request req, CoyoteRequest request)
Parse session id in URL.protected boolean postParseRequest(Request req, CoyoteRequest request, Response res, CoyoteResponse response)
Parse additional request parameters.void service(Request req, Response res)
Service method.
Methods inherited from class java.lang.Object clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail ADAPTER_NOTES
public static final int ADAPTER_NOTES
- See Also:
- Constant Field Values
sm
protected StringManager sm
- The string manager for this package.
Constructor Detail CoyoteAdapter
public CoyoteAdapter(CoyoteConnector connector)
- Construct a new CoyoteProcessor associated with the specified connector.
- Parameters:
- connector - CoyoteConnector that owns this processor
Method Detail service
public void service(Request req, Response res) throws java.lang.Exception
- Service method.
- Specified by:
- service in interface Adapter
- Throws:
- java.lang.Exception - if an error happens during handling of the request. Common errors are:
Tomcat should be able to handle and log any other exception ( including runtime exceptions )
- IOException if an input/output error occurs and we are processing an included servlet (otherwise it is swallowed and handled by the top level error handler mechanism)
- ServletException if a servlet throws an exception and we are processing an included servlet (otherwise it is swallowed and handled by the top level error handler mechanism)
postParseRequest
protected boolean postParseRequest(Request req, CoyoteRequest request, Response res, CoyoteResponse response) throws java.lang.Exception
- Parse additional request parameters.
- Throws:
- java.lang.Exception
parseSessionId
protected void parseSessionId(Request req, CoyoteRequest request)
- Parse session id in URL.
parseSessionCookiesId
protected void parseSessionCookiesId(Request req, CoyoteRequest request)
- Parse session id in URL.
convertURI
protected void convertURI(MessageBytes uri, CoyoteRequest request) throws java.lang.Exception
- Character conversion of the URI.
- Throws:
- java.lang.Exception
normalize
public static boolean normalize(MessageBytes uriMB)
- Normalize URI.
This method normalizes "\", "//", "/./" and "/../". This method will return false when trying to go above the root, or if the URI contains a null byte.
- Parameters:
- uriMB - URI to be normalized
copyBytes
protected static void copyBytes(byte[] b, int dest, int src, int len)
- Copy an array of bytes to a different position. Used during normalization.
log
protected void log(java.lang.String message)
- Log a message on the Logger associated with our Container (if any)
- Parameters:
- message - Message to be logged
log
protected void log(java.lang.String message, java.lang.Throwable throwable)
- Log a message on the Logger associated with our Container (if any)
- Parameters:
- message - Message to be logged
- throwable - Associated exception
Overview Package Class Tree Deprecated Help PREV CLASS NEXT CLASS FRAMES NO FRAMES SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD
Copyright © 2000-2003 Apache Software Foundation. All Rights Reserved.