Top Description Methods
org.apache.http.protocol

public Interface HttpResponseInterceptorList

Known Direct Implementers
org.apache.http.protocol.BasicHttpProcessor
Annotations
@Deprecated
Imports
java.util.List, org.apache.http.HttpResponseInterceptor

Deprecated

(4.3)

Provides access to an ordered list of response interceptors. Lists are expected to be built upfront and used read-only afterwards for processing.
Since
4.0

Method Summary

Modifier and TypeMethod and Description
public void
addResponseInterceptor(HttpResponseInterceptor
the response interceptor to add
interceptor
)

Appends a response interceptor to this list.

public void
addResponseInterceptor(HttpResponseInterceptor
the response interceptor to add
interceptor
,
int
the index to insert the interceptor at
index
)

Inserts a response interceptor at the specified index.

public void
clearResponseInterceptors()

Removes all response interceptors from this list.

public HttpResponseInterceptor

Returns:

the interceptor at the given index, or null if the index is out of range
getResponseInterceptor
(int
the index of the interceptor to obtain, 0 for first
index
)

Obtains a response interceptor from this list.

public int

Returns:

the number of response interceptors in this list
getResponseInterceptorCount
()

Obtains the current size of this list.

public void
removeResponseInterceptorByClass(Class<? extends HttpResponseInterceptor>
the class of the instances to be removed.
clazz
)

Removes all response interceptor of the specified class

public void
setInterceptors(List<?>
the list of response interceptors
list
)

Sets the response interceptors in this list.

Method Detail

addResponseInterceptorback to summary
public void addResponseInterceptor(HttpResponseInterceptor interceptor)

Appends a response interceptor to this list.

Parameters
interceptor:HttpResponseInterceptor

the response interceptor to add

addResponseInterceptorback to summary
public void addResponseInterceptor(HttpResponseInterceptor interceptor, int index)

Inserts a response interceptor at the specified index.

Parameters
interceptor:HttpResponseInterceptor

the response interceptor to add

index:int

the index to insert the interceptor at

clearResponseInterceptorsback to summary
public void clearResponseInterceptors()

Removes all response interceptors from this list.

getResponseInterceptorback to summary
public HttpResponseInterceptor getResponseInterceptor(int index)

Obtains a response interceptor from this list.

Parameters
index:int

the index of the interceptor to obtain, 0 for first

Returns:HttpResponseInterceptor

the interceptor at the given index, or null if the index is out of range

getResponseInterceptorCountback to summary
public int getResponseInterceptorCount()

Obtains the current size of this list.

Returns:int

the number of response interceptors in this list

removeResponseInterceptorByClassback to summary
public void removeResponseInterceptorByClass(Class<? extends HttpResponseInterceptor> clazz)

Removes all response interceptor of the specified class

Parameters
clazz:Class<? extends HttpResponseInterceptor>

the class of the instances to be removed.

setInterceptorsback to summary
public void setInterceptors(List<?> list)

Sets the response interceptors in this list. This list will be cleared and re-initialized to contain all response interceptors from the argument list. If the argument list includes elements that are not response interceptors, the behavior is implementation dependent.

Parameters
list:List<?>

the list of response interceptors