RequestBody
Types
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Returns the number of bytes that will be written to sink in a call to writeTo, or -1 if that count is unknown.
Link copied to clipboard
Returns the Content-Type header for this body.
Link copied to clipboard
Returns a gzip version of the RequestBody, with compressed payload. This is not automatic as not all servers support gzip compressed requests.
Link copied to clipboard
Returns true if this body expects at most one call to writeTo and can be transmitted at most once. This is typically used when writing the request body is destructive and it is not possible to recreate the request body after it has been sent.