|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface HttpRequestContext
An abstraction of a HTTP request.
Field Summary |
---|
Fields inherited from interface javax.ws.rs.core.HttpHeaders |
---|
ACCEPT, ACCEPT_CHARSET, ACCEPT_ENCODING, ACCEPT_LANGUAGE, AUTHORIZATION, CACHE_CONTROL, CONTENT_ENCODING, CONTENT_LANGUAGE, CONTENT_LENGTH, CONTENT_LOCATION, CONTENT_TYPE, COOKIE, DATE, ETAG, EXPIRES, HOST, IF_MATCH, IF_MODIFIED_SINCE, IF_NONE_MATCH, IF_UNMODIFIED_SINCE, LAST_MODIFIED, LOCATION, SET_COOKIE, USER_AGENT, VARY, WWW_AUTHENTICATE |
Fields inherited from interface javax.ws.rs.core.SecurityContext |
---|
BASIC_AUTH, CLIENT_CERT_AUTH, DIGEST_AUTH, FORM_AUTH |
Method Summary | ||
---|---|---|
java.net.URI |
getAbsolutePath()
Get the absolute path URI of the request. |
|
javax.ws.rs.core.MediaType |
getAcceptableMediaType(java.util.List<javax.ws.rs.core.MediaType> mediaTypes)
Select the first media type, from a list of media types, that is most acceptable according to the requested acceptable media types. |
|
java.net.URI |
getBaseUri()
Get the base URI of the request. |
|
javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> |
getCookieNameValueMap()
Get the cookie name value map. |
|
|
getEntity(java.lang.Class<T> type)
Get the request entity, returns null if the request does not contain an entity body. |
|
|
getEntity(java.lang.Class<T> type,
java.lang.reflect.Type genericType,
java.lang.annotation.Annotation[] as)
Get the request entity, returns null if the request does not contain an entity body. |
|
java.lang.String |
getHeaderValue(java.lang.String name)
Get a HTTP header value. |
|
java.lang.String |
getHttpMethod()
Get the HTTP method name. |
|
java.net.URI |
getRequestUri()
Get the (complete) request URI. |
Methods inherited from interface javax.ws.rs.core.HttpHeaders |
---|
getAcceptableLanguages, getAcceptableMediaTypes, getCookies, getLanguage, getMediaType, getRequestHeader, getRequestHeaders |
Methods inherited from interface javax.ws.rs.core.Request |
---|
evaluatePreconditions, evaluatePreconditions, evaluatePreconditions, selectVariant |
Methods inherited from interface javax.ws.rs.core.SecurityContext |
---|
getAuthenticationScheme, getUserPrincipal, isSecure, isUserInRole |
Method Detail |
---|
java.lang.String getHttpMethod()
java.net.URI getBaseUri()
java.net.URI getRequestUri()
java.net.URI getAbsolutePath()
java.lang.String getHeaderValue(java.lang.String name)
name
- the HTTP header
javax.ws.rs.core.MediaType getAcceptableMediaType(java.util.List<javax.ws.rs.core.MediaType> mediaTypes)
mediaTypes
- the list of media types
javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> getCookieNameValueMap()
<T> T getEntity(java.lang.Class<T> type) throws javax.ws.rs.WebApplicationException
type
- the type of entity
javax.ws.rs.WebApplicationException
- if the content of the request
cannot be mapped to an entity of the requested type<T> T getEntity(java.lang.Class<T> type, java.lang.reflect.Type genericType, java.lang.annotation.Annotation[] as) throws javax.ws.rs.WebApplicationException
type
- the type of entitygenericType
- type the generic type of entity, it is the responsibility
of the callee to ensure that the type and generic type are
consistent otherwise the behvaiour of this method is undefned.as
- the annoations associated with the type
javax.ws.rs.WebApplicationException
- if the content of the request
cannot be mapped to an entity of the requested type
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |