org.littleshoot.proxy
Interface HttpFilter

All Superinterfaces:
HttpRequestMatcher
All Known Implementing Classes:
DefaultHttpFilter, NoOpHttpFilter

public interface HttpFilter
extends HttpRequestMatcher

Interface for rules for filtering HTTP traffic.


Method Summary
 org.jboss.netty.handler.codec.http.HttpResponse filterResponse(org.jboss.netty.handler.codec.http.HttpRequest request, org.jboss.netty.handler.codec.http.HttpResponse response)
          Filters the HTTP response.
 int getMaxResponseSize()
          Returns the maximum response size to expect in bytes for this filter.
 
Methods inherited from interface org.littleshoot.proxy.HttpRequestMatcher
filterResponses
 

Method Detail

filterResponse

org.jboss.netty.handler.codec.http.HttpResponse filterResponse(org.jboss.netty.handler.codec.http.HttpRequest request,
                                                               org.jboss.netty.handler.codec.http.HttpResponse response)
Filters the HTTP response.

Parameters:
request - The HTTP request associated with the response.
response - The response to filter.
Returns:
The filtered response.

getMaxResponseSize

int getMaxResponseSize()
Returns the maximum response size to expect in bytes for this filter. You should set this as small as possible to save memory, but of course not smaller than response body sizes will be.

Returns:
The maximum response body size to support for this filter, in bytes.


Copyright © 2009-2013 LittleShoot. All Rights Reserved.