pub trait BodyEncode: Encode {
// Provided method
fn update_header(&self, header: &mut HeaderMut<'_>) -> Result<()> { ... }
}
Expand description
BodyEncode
is used for representing HTTP body encoders.
Provided Methods§
Sourcefn update_header(&self, header: &mut HeaderMut<'_>) -> Result<()>
fn update_header(&self, header: &mut HeaderMut<'_>) -> Result<()>
This method is called before starting to encode a HTTP body.
It is used for adjusting HTTP header by using the encoder specific information.
The default implementation does nothing.