An empty HTTP content body (empty stream and Content-Length: 0
header).
Create a new content body from value a.
Create a new content body from value a.
a scala value that we want to transform into an HTTP content.
a ContentDecoder that knows how to encode values of type A
.
an HTTP content ready to be consumed or sent over the network.
Build HTTP message content body.
Given an existing ContentDecoder for a type
A
, this object allows to create HTTP content fromA
values. Meaning, it will encode the value into a stream of bytes, and a set of appropriate HTTP headers.