Gets the current body buffer as a . If a positive limit is provided the parsing will only happen if the buffer length is smaller or equal to the limit. Otherwise an IllegalStateException is thrown.
When the application is only handling uploads in JSON format, it is recommended to set a limit on {@link BodyHandler#setBodyLimit} as this will avoid the upload to be parsed and loaded into the application memory.
Get the entire HTTP request body as a string, assuming the specified encoding. The context must have first been routed to a BodyHandler for this to be populated.
Return true
if a BodyHandler was executed before this call in the lifetime
of the request.
A body can be empty if it is not available, or its length is 0
.
Returns the total length of the body buffer. This is the length in bytes. When there is no buffer the length is
-1
.
Generated using TypeDoc
Gets the current body buffer as a . If a positive limit is provided the parsing will only happen if the buffer length is smaller or equal to the limit. Otherwise an IllegalStateException is thrown.
When the application is only handling uploads in JSON format, it is recommended to set a limit on {@link BodyHandler#setBodyLimit} as this will avoid the upload to be parsed and loaded into the application memory.