public class HttpServerRequestImpl extends HttpRequestImpl implements HttpServerRequest
UrlAccessor.UrlBuilder, UrlAccessor.UrlMutator, UrlAccessor.UrlProperty
HttpMethodAccessor.HttpMethodBuilder<B extends HttpMethodAccessor.HttpMethodBuilder<B>>, HttpMethodAccessor.HttpMethodMutator, HttpMethodAccessor.HttpMethodProperty
HeaderFieldsAccessor.HeaderFieldsBuilder<T extends HeaderFields<?,?>,B extends HeaderFieldsAccessor.HeaderFieldsBuilder<T,B>>, HeaderFieldsAccessor.HeaderFieldsMutator<T extends HeaderFields<?,?>>, HeaderFieldsAccessor.HeaderFieldsProperty<T extends HeaderFields<?,?>>
HttpBodyAccessor.HttpBodyBuilder<B extends HttpBodyAccessor.HttpBodyBuilder<B>>, HttpBodyAccessor.HttpBodyMutator, HttpBodyAccessor.HttpBodyProperty, HttpBodyAccessor.HttpBodyProvider<EXC extends Exception>
HttpInputStreamAccessor.HttpInputStreamBuilder<B extends HttpInputStreamAccessor.HttpInputStreamBuilder<B>>, HttpInputStreamAccessor.HttpInputStreamMutator, HttpInputStreamAccessor.HttpInputStreamProperty, HttpInputStreamAccessor.HttpInputStreamProvider<EXC extends Exception>
Modifier and Type | Field and Description |
---|---|
protected MediaTypeFactoryLookup |
_mediaTypeFactoryLookup |
_headerFields, _httpMethod, _url
Constructor and Description |
---|
HttpServerRequestImpl(HttpMethod aHttpMethod,
Url aUrl,
RequestHeaderFields aHeaderFields,
InputStream aHttpInputStream,
MediaTypeFactoryLookup aMediaTypeFactoryLookup)
Constructs a
HttpServerRequest with all required attributes. |
Modifier and Type | Method and Description |
---|---|
String |
getHttpBody()
Retrieves the HTTP body from the HTTP body property.
|
InputStream |
getHttpInputStream()
Retrieves the
InputStream from the HTTP InputStream
property. |
<REQ> REQ |
getRequest(Class<REQ> aRequestType)
This method's implementation supports the
HttpBodyMap to
unmarshal an HTTP Request-Body into an HttpBodyMap when providing
the HttpBodyMap as request type. |
getHeaderFields, getHttpMethod, getUrl
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getRequest
getUrl
getHttpMethod
getHeaderFields
protected MediaTypeFactoryLookup _mediaTypeFactoryLookup
public HttpServerRequestImpl(HttpMethod aHttpMethod, Url aUrl, RequestHeaderFields aHeaderFields, InputStream aHttpInputStream, MediaTypeFactoryLookup aMediaTypeFactoryLookup)
HttpServerRequest
with all required attributes.aHttpMethod
- The HttpMethod
with which the request has been
sent.aUrl
- The Url
from which to take the URL specific data.aHeaderFields
- The RequestHeaderFields
sent by the request.aHttpInputStream
- The InputStream
representing the
request's HTTP body.aMediaTypeFactoryLookup
- The lookup factory for retrieving the
required MediaType
factories.public <REQ> REQ getRequest(Class<REQ> aRequestType) throws BadRequestException
HttpBodyMap
to
unmarshal an HTTP Request-Body into an HttpBodyMap
when providing
the HttpBodyMap
as request type.getRequest
in interface HttpServerRequest
REQ
- the generic typeaRequestType
- the request typeBadRequestException
- the bad request exceptionpublic InputStream getHttpInputStream()
InputStream
from the HTTP InputStream
property.getHttpInputStream
in interface HttpInputStreamAccessor
InputStream
stored by the InputStream
property.public String getHttpBody()
getHttpBody
in interface HttpBodyAccessor
Copyright © 2018. All rights reserved.