com.ning.http.client.filter
Interface ResponseFilter
public interface ResponseFilter
A Filter interface that gets invoked before making the processing of the response bytes. ResponseFilter are invoked
before the actual response's status code get processed. That means authorization, proxy authentication and redirects
processing hasn't occured when ResponseFilter gets invoked.
filter
FilterContext filter(FilterContext ctx)
throws FilterException
- An
AsyncHttpProvider will invoke filter(com.ning.http.client.filter.FilterContext) and will use the
returned FilterContext.replayRequest() and FilterContext.getAsyncHandler() to decide if the response
processing can continue. If FilterContext.replayRequest() return true, a new request will be made
using FilterContext.getRequest() and the current response processing will be ignored.
- Parameters:
ctx - a FilterContext
- Returns:
FilterContext. The FilterContext instance may not the same as the original one.
- Throws:
FilterException - to interrupt the filter processing.
Copyright © 2011. All Rights Reserved.