Package io.micronaut.http
Interface ServerHttpRequest<B>
- Type Parameters:
B
- The body type
- All Superinterfaces:
AttributeHolder
,HttpMessage<B>
,HttpRequest<B>
,MutableAttributeHolder
- All Known Implementing Classes:
NettyHttpRequest
This interface extends
HttpRequest
with methods that are specific to a request received
by an HTTP server.-
Field Summary
Fields inherited from interface io.micronaut.http.HttpRequest
SCHEME_HTTP, SCHEME_HTTPS
-
Method Summary
Methods inherited from interface io.micronaut.core.attr.AttributeHolder
getAttribute, getAttribute
Methods inherited from interface io.micronaut.http.HttpMessage
getAttributes, getBody, getBody, getBody, getBody, getBodyWriter, getCharacterEncoding, getContentLength, getContentType, getHeaders
Methods inherited from interface io.micronaut.http.HttpRequest
accept, getCertificate, getCookies, getHttpVersion, getLocale, getMethod, getMethodName, getOrigin, getParameters, getPath, getRemoteAddress, getServerAddress, getServerName, getSslSession, getUri, getUserPrincipal, getUserPrincipal, isSecure, mutate, setAttribute, toMutableRequest
Methods inherited from interface io.micronaut.core.attr.MutableAttributeHolder
removeAttribute
-
Method Details
-
byteBody
Get the bytes of the body. The body is owned by the request, so the caller should generally not close it or do any primary operations. The body is usually consumed by the argument binder of the controller, e.g. if it has a@Body
argument. If you want to use the body,ByteBody.split(ByteBody.SplitBackpressureMode)
it first.- Returns:
- The body bytes of this request
-