Interface w3c.www.protocol.http.RequestFilter
All Packages Class Hierarchy This Package Previous Next Index
Interface w3c.www.protocol.http.RequestFilter
- public interface RequestFilter
- extends Object
The request filter interface.
Filters allow application wide request enhancement before they are being
actually emited on the wire.
Once registered to the HttpManager, a request filter will be invoked
before the request is actualy sent to the wire, and right
after the reply headers are available, only if its
current scope matches the request URL.
-
ingoingFilter(Request)
- The request pre-processing hook.
-
outgoingFilter(Request, Reply)
- The request post-processing hook.
ingoingFilter
public abstract Reply ingoingFilter(Request request) throws HttpException
- The request pre-processing hook.
Before each request is launched, all filters will be called back through
this method. They will generally set up additional request header
fields to enhance the request.
- Parameters:
- request - The request that is about to be launched.
- Returns:
- An instance of Reply if the filter could handle the request,
or null if processing should continue normally.
outgoingFilter
public abstract Reply outgoingFilter(Request request,
Reply reply) throws HttpException
- The request post-processing hook.
After each request has been replied to by the target server (be it a
proxy or the actual origin server), each filter's outgoingFilter
method is called.
It gets the original request, and the actaul reply as a parameter,
and should return whatever reply it wants the caller to get.
- Parameters:
- request - The original (handled) request.
- reply - The reply, as emited by the target server, or constructed
by some other filter.
All Packages Class Hierarchy This Package Previous Next Index