public class HttpCoreContext extends Object implements HttpContext
HttpContext that provides convenience
 setters for user assignable attributes and getter for readable attributes.| Modifier and Type | Field and Description | 
|---|---|
| static String | CONNECTION_ENDPOINTAttribute name of a  EndpointDetailsobject that
 represents the actual connection endpoint details. | 
| static String | HTTP_REQUESTAttribute name of a  HttpRequestobject that
 represents the actual HTTP request. | 
| static String | HTTP_RESPONSEAttribute name of a  HttpResponseobject that
 represents the actual HTTP response. | 
| static String | SSL_SESSIONAttribute name of a  SSLSessionobject that
 represents the actual connection endpoint details. | 
RESERVED_PREFIX| Constructor and Description | 
|---|
| HttpCoreContext() | 
| HttpCoreContext(HttpContext context) | 
| Modifier and Type | Method and Description | 
|---|---|
| static HttpCoreContext | adapt(HttpContext context) | 
| static HttpCoreContext | create() | 
| Object | getAttribute(String id)Obtains attribute with the given name. | 
| <T> T | getAttribute(String attribname,
            Class<T> clazz) | 
| EndpointDetails | getEndpointDetails() | 
| ProtocolVersion | getProtocolVersion()Returns protocol version used in this context. | 
| HttpRequest | getRequest() | 
| HttpResponse | getResponse() | 
| SSLSession | getSSLSession() | 
| Object | removeAttribute(String id)Removes attribute with the given name from the context. | 
| Object | setAttribute(String id,
            Object obj)Sets value of the attribute with the given name. | 
| void | setProtocolVersion(ProtocolVersion version)Sets protocol version used in this context. | 
public static final String CONNECTION_ENDPOINT
EndpointDetails object that
 represents the actual connection endpoint details.public static final String SSL_SESSION
SSLSession object that
 represents the actual connection endpoint details.public static final String HTTP_REQUEST
HttpRequest object that
 represents the actual HTTP request.public static final String HTTP_RESPONSE
HttpResponse object that
 represents the actual HTTP response.public HttpCoreContext(HttpContext context)
public HttpCoreContext()
public static HttpCoreContext create()
public static HttpCoreContext adapt(HttpContext context)
public ProtocolVersion getProtocolVersion()
HttpContextgetProtocolVersion in interface HttpContextpublic void setProtocolVersion(ProtocolVersion version)
HttpContextsetProtocolVersion in interface HttpContextpublic Object getAttribute(String id)
HttpContextgetAttribute in interface HttpContextid - the attribute name.null if not set.public Object setAttribute(String id, Object obj)
HttpContextsetAttribute in interface HttpContextid - the attribute name.obj - the attribute value.id, or
         null if there was no mapping for id.public Object removeAttribute(String id)
HttpContextremoveAttribute in interface HttpContextid - the attribute name.null if not set.public SSLSession getSSLSession()
public EndpointDetails getEndpointDetails()
public HttpRequest getRequest()
public HttpResponse getResponse()
Copyright © 2005–2022 The Apache Software Foundation. All rights reserved.