Body

interface Body : Closeable

If this Body is NOT being returned to the caller (via a Server implementation or otherwise), close() should be called.

Inheritors

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
abstract val length: Long?

Will be null for bodies where it's impossible to a priori determine - e.g. StreamBody

Link copied to clipboard
abstract val payload: ByteBuffer
Link copied to clipboard
abstract val stream: InputStream

Functions

Link copied to clipboard
abstract override fun close()
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Body.gzipped(compressionLevel: Int = DEFAULT_COMPRESSION): CompressionResult
Link copied to clipboard
fun Body.gzippedStream(compressionLevel: Int = DEFAULT_COMPRESSION): CompressionResult