public class HttpClientContext
extends HttpCoreContext
HttpContext attributes used in the course
of HTTP request execution.| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
AUTH_CACHE
Attribute name of a
AuthCache object
that represents the auth scheme cache. |
static java.lang.String |
AUTH_EXCHANGE_MAP
Attribute name of a map containing actual
AuthExchanges keyed by their respective
org.apache.hc.core5.http.HttpHost. |
static java.lang.String |
AUTHSCHEME_REGISTRY
Attribute name of a
org.apache.hc.core5.http.config.Lookup object that represents
the actual AuthSchemeFactory registry. |
static java.lang.String |
COOKIE_ORIGIN
Attribute name of a
CookieOrigin
object that represents the actual details of the origin server. |
static java.lang.String |
COOKIE_SPEC
Attribute name of a
CookieSpec
object that represents the actual cookie specification. |
static java.lang.String |
COOKIE_STORE
Attribute name of a
CookieStore
object that represents the actual cookie store. |
static java.lang.String |
COOKIESPEC_REGISTRY
Attribute name of a
org.apache.hc.core5.http.config.Lookup object that represents
the actual CookieSpecFactory registry. |
static java.lang.String |
CREDS_PROVIDER
Attribute name of a
CredentialsProvider
object that represents the actual credentials provider. |
static java.lang.String |
EXCHANGE_ID
Attribute name of a
String object that represents the ID of the
current message exchange. |
static java.lang.String |
HTTP_ROUTE
Attribute name of a
RouteInfo
object that represents the actual connection route. |
static java.lang.String |
REDIRECT_LOCATIONS
Attribute name of a
RedirectLocations object that represents a collection of all
redirect locations received in the process of request execution. |
static java.lang.String |
REQUEST_CONFIG
Attribute name of a
RequestConfig object that
represents the actual request configuration. |
static java.lang.String |
USER_TOKEN
Attribute name of a
Object object that represents
the actual user identity such as user Principal. |
| Constructor and Description |
|---|
HttpClientContext() |
HttpClientContext(HttpContext context) |
public static final java.lang.String HTTP_ROUTE
RouteInfo
object that represents the actual connection route.public static final java.lang.String REDIRECT_LOCATIONS
RedirectLocations object that represents a collection of all
redirect locations received in the process of request execution.public static final java.lang.String COOKIESPEC_REGISTRY
org.apache.hc.core5.http.config.Lookup object that represents
the actual CookieSpecFactory registry.public static final java.lang.String COOKIE_SPEC
CookieSpec
object that represents the actual cookie specification.public static final java.lang.String COOKIE_ORIGIN
CookieOrigin
object that represents the actual details of the origin server.public static final java.lang.String COOKIE_STORE
CookieStore
object that represents the actual cookie store.public static final java.lang.String CREDS_PROVIDER
CredentialsProvider
object that represents the actual credentials provider.public static final java.lang.String AUTH_CACHE
AuthCache object
that represents the auth scheme cache.public static final java.lang.String AUTH_EXCHANGE_MAP
AuthExchanges keyed by their respective
org.apache.hc.core5.http.HttpHost.public static final java.lang.String USER_TOKEN
Object object that represents
the actual user identity such as user Principal.public static final java.lang.String AUTHSCHEME_REGISTRY
org.apache.hc.core5.http.config.Lookup object that represents
the actual AuthSchemeFactory registry.public static final java.lang.String REQUEST_CONFIG
RequestConfig object that
represents the actual request configuration.public static final java.lang.String EXCHANGE_ID
String object that represents the ID of the
current message exchange.public HttpClientContext(HttpContext context)
public HttpClientContext()
public static HttpClientContext adapt(HttpContext context)
public static HttpClientContext create()
public RouteInfo getHttpRoute()
public RedirectLocations getRedirectLocations()
public CookieStore getCookieStore()
public void setCookieStore(CookieStore cookieStore)
public CookieSpec getCookieSpec()
public CookieOrigin getCookieOrigin()
public <any> getCookieSpecRegistry()
public void setCookieSpecRegistry(<any> lookup)
public <any> getAuthSchemeRegistry()
public void setAuthSchemeRegistry(<any> lookup)
public CredentialsProvider getCredentialsProvider()
public void setCredentialsProvider(CredentialsProvider credentialsProvider)
public AuthCache getAuthCache()
public void setAuthCache(AuthCache authCache)
public java.util.Map<HttpHost,AuthExchange> getAuthExchanges()
public AuthExchange getAuthExchange(HttpHost host)
public void setAuthExchange(HttpHost host,
AuthExchange authExchange)
public void resetAuthExchange(HttpHost host,
AuthScheme authScheme)
public <T> T getUserToken(java.lang.Class<T> clazz)
public java.lang.Object getUserToken()
public void setUserToken(java.lang.Object obj)
public RequestConfig getRequestConfig()
public void setRequestConfig(RequestConfig config)
public java.lang.String getExchangeId()
public void setExchangeId(java.lang.String id)