@NotThreadSafe @Deprecated public final class BasicHttpProcessor extends java.lang.Object implements HttpProcessor, HttpRequestInterceptorList, HttpResponseInterceptorList, java.lang.Cloneable
HttpProcessor.
Please note access to the internal structures of this class is not synchronized and therefore this class may be thread-unsafe.
| 限定符和类型 | 字段和说明 |
|---|---|
protected java.util.List<HttpRequestInterceptor> |
requestInterceptors
已过时。
|
protected java.util.List<HttpResponseInterceptor> |
responseInterceptors
已过时。
|
| 构造器和说明 |
|---|
BasicHttpProcessor()
已过时。
|
| 限定符和类型 | 方法和说明 |
|---|---|
void |
addInterceptor(HttpRequestInterceptor interceptor)
已过时。
|
void |
addInterceptor(HttpRequestInterceptor interceptor,
int index)
已过时。
|
void |
addInterceptor(HttpResponseInterceptor interceptor)
已过时。
|
void |
addInterceptor(HttpResponseInterceptor interceptor,
int index)
已过时。
|
void |
addRequestInterceptor(HttpRequestInterceptor itcp)
已过时。
Appends a request interceptor to this list.
|
void |
addRequestInterceptor(HttpRequestInterceptor itcp,
int index)
已过时。
Inserts a request interceptor at the specified index.
|
void |
addResponseInterceptor(HttpResponseInterceptor itcp)
已过时。
Appends a response interceptor to this list.
|
void |
addResponseInterceptor(HttpResponseInterceptor itcp,
int index)
已过时。
Inserts a response interceptor at the specified index.
|
void |
clearInterceptors()
已过时。
Clears both interceptor lists maintained by this processor.
|
void |
clearRequestInterceptors()
已过时。
Removes all request interceptors from this list.
|
void |
clearResponseInterceptors()
已过时。
Removes all response interceptors from this list.
|
java.lang.Object |
clone()
已过时。
|
BasicHttpProcessor |
copy()
已过时。
Creates a copy of this instance
|
protected void |
copyInterceptors(BasicHttpProcessor target)
已过时。
Sets up the target to have the same list of interceptors
as the current instance.
|
HttpRequestInterceptor |
getRequestInterceptor(int index)
已过时。
Obtains a request interceptor from this list.
|
int |
getRequestInterceptorCount()
已过时。
Obtains the current size of this list.
|
HttpResponseInterceptor |
getResponseInterceptor(int index)
已过时。
Obtains a response interceptor from this list.
|
int |
getResponseInterceptorCount()
已过时。
Obtains the current size of this list.
|
void |
process(HttpRequest request,
HttpContext context)
已过时。
Processes a request.
|
void |
process(HttpResponse response,
HttpContext context)
已过时。
Processes a response.
|
void |
removeRequestInterceptorByClass(java.lang.Class<? extends HttpRequestInterceptor> clazz)
已过时。
Removes all request interceptor of the specified class
|
void |
removeResponseInterceptorByClass(java.lang.Class<? extends HttpResponseInterceptor> clazz)
已过时。
Removes all response interceptor of the specified class
|
void |
setInterceptors(java.util.List<?> list)
已过时。
Sets the interceptor lists.
|
protected final java.util.List<HttpRequestInterceptor> requestInterceptors
protected final java.util.List<HttpResponseInterceptor> responseInterceptors
public void addRequestInterceptor(HttpRequestInterceptor itcp)
HttpRequestInterceptorListaddRequestInterceptor 在接口中 HttpRequestInterceptorListitcp - the request interceptor to addpublic void addRequestInterceptor(HttpRequestInterceptor itcp, int index)
HttpRequestInterceptorListaddRequestInterceptor 在接口中 HttpRequestInterceptorListitcp - the request interceptor to addindex - the index to insert the interceptor atpublic void addResponseInterceptor(HttpResponseInterceptor itcp, int index)
HttpResponseInterceptorListaddResponseInterceptor 在接口中 HttpResponseInterceptorListitcp - the response interceptor to addindex - the index to insert the interceptor atpublic void removeRequestInterceptorByClass(java.lang.Class<? extends HttpRequestInterceptor> clazz)
HttpRequestInterceptorListremoveRequestInterceptorByClass 在接口中 HttpRequestInterceptorListclazz - the class of the instances to be removed.public void removeResponseInterceptorByClass(java.lang.Class<? extends HttpResponseInterceptor> clazz)
HttpResponseInterceptorListremoveResponseInterceptorByClass 在接口中 HttpResponseInterceptorListclazz - the class of the instances to be removed.public final void addInterceptor(HttpRequestInterceptor interceptor)
public final void addInterceptor(HttpRequestInterceptor interceptor, int index)
public int getRequestInterceptorCount()
HttpRequestInterceptorListgetRequestInterceptorCount 在接口中 HttpRequestInterceptorListpublic HttpRequestInterceptor getRequestInterceptor(int index)
HttpRequestInterceptorListgetRequestInterceptor 在接口中 HttpRequestInterceptorListindex - the index of the interceptor to obtain,
0 for firstnull if the index is out of rangepublic void clearRequestInterceptors()
HttpRequestInterceptorListpublic void addResponseInterceptor(HttpResponseInterceptor itcp)
HttpResponseInterceptorListaddResponseInterceptor 在接口中 HttpResponseInterceptorListitcp - the response interceptor to addpublic final void addInterceptor(HttpResponseInterceptor interceptor)
public final void addInterceptor(HttpResponseInterceptor interceptor, int index)
public int getResponseInterceptorCount()
HttpResponseInterceptorListgetResponseInterceptorCount 在接口中 HttpResponseInterceptorListpublic HttpResponseInterceptor getResponseInterceptor(int index)
HttpResponseInterceptorListgetResponseInterceptor 在接口中 HttpResponseInterceptorListindex - the index of the interceptor to obtain,
0 for firstnull if the index is out of rangepublic void clearResponseInterceptors()
HttpResponseInterceptorListpublic void setInterceptors(java.util.List<?> list)
setInterceptors 在接口中 HttpRequestInterceptorListsetInterceptors 在接口中 HttpResponseInterceptorListlist - the list of request and response interceptors
from which to initializepublic void clearInterceptors()
public void process(HttpRequest request, HttpContext context) throws java.io.IOException, HttpException
HttpRequestInterceptorprocess 在接口中 HttpRequestInterceptorrequest - the request to preprocesscontext - the context for the requestjava.io.IOException - in case of an I/O errorHttpException - in case of an HTTP protocol violationpublic void process(HttpResponse response, HttpContext context) throws java.io.IOException, HttpException
HttpResponseInterceptorprocess 在接口中 HttpResponseInterceptorresponse - the response to postprocesscontext - the context for the requestjava.io.IOException - in case of an I/O errorHttpException - in case of an HTTP protocol violationprotected void copyInterceptors(BasicHttpProcessor target)
target - object to be initialisedpublic BasicHttpProcessor copy()
public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone 在类中 java.lang.Objectjava.lang.CloneNotSupportedException