|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ning.http.client.filter.ThrottleRequestFilter
public class ThrottleRequestFilter
A RequestFilter throttles requests and block when the number of permits is reached, waiting for
the response to arrives before executing the next request.
| Constructor Summary | |
|---|---|
ThrottleRequestFilter(int maxConnections)
|
|
ThrottleRequestFilter(int maxConnections,
int maxWait)
|
|
| Method Summary | |
|---|---|
FilterContext |
filter(FilterContext ctx)
An AsyncHttpProvider will invoke RequestFilter.filter(com.ning.http.client.filter.FilterContext) and will use the
returned FilterContext.getRequest() and FilterContext.getAsyncHandler() to continue the request
processing. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ThrottleRequestFilter(int maxConnections)
public ThrottleRequestFilter(int maxConnections,
int maxWait)
| Method Detail |
|---|
public FilterContext filter(FilterContext ctx)
throws FilterException
RequestFilterAsyncHttpProvider will invoke RequestFilter.filter(com.ning.http.client.filter.FilterContext) and will use the
returned FilterContext.getRequest() and FilterContext.getAsyncHandler() to continue the request
processing.
filter in interface RequestFilterctx - a FilterContext
FilterContext. The FilterContext instance may not the same as the original one.
FilterException - to interrupt the filter processing.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||