Package io.micronaut.http.util
Class HttpUtil
java.lang.Object
io.micronaut.http.util.HttpUtil
Utility methods for HTTP handling.
- Since:
- 1.0
- Author:
- Graeme Rocher
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetCharset
(@NonNull HttpMessage<?> request) Resolve theCharset
to use for the request.static boolean
isFormData
(HttpRequest<?> request) Return whether the given request featuresMediaType.APPLICATION_FORM_URLENCODED
orMediaType.MULTIPART_FORM_DATA
.resolveCharset
(@NonNull HttpMessage<?> request) Resolve theCharset
to use for the request.
-
Constructor Details
-
HttpUtil
public HttpUtil()
-
-
Method Details
-
isFormData
Return whether the given request featuresMediaType.APPLICATION_FORM_URLENCODED
orMediaType.MULTIPART_FORM_DATA
.- Parameters:
request
- The request- Returns:
- True if it is form data
-
resolveCharset
Resolve theCharset
to use for the request. -
getCharset
Resolve theCharset
to use for the request.
-