Enum actix_web::http::ContentEncoding [−][src]
pub enum ContentEncoding { Auto, Br, Deflate, Gzip, Zstd, Identity, }
Expand description
Represents a supported content encoding.
Variants
Automatically select encoding based on encoding negotiation.
A format using the Brotli algorithm.
A format using the zlib structure with deflate algorithm.
Gzip algorithm.
Indicates the identity function (i.e. no compression, nor modification).
Implementations
Trait Implementations
Returns the “default value” for a type. Read more
Performs the conversion.
type Err = Infallible
type Err = Infallible
The associated error which can be returned from parsing.
Parses a string s
to return a value of this type. Read more
Returns the name of the header field
Parse a header
type Error = InvalidHeaderValue
type Error = InvalidHeaderValue
The type returned in the event of a conversion error.
pub fn try_into_value(
self
) -> Result<HeaderValue, <ContentEncoding as IntoHeaderValue>::Error>
pub fn try_into_value(
self
) -> Result<HeaderValue, <ContentEncoding as IntoHeaderValue>::Error>
Try to convert value to a HeaderValue.
Auto Trait Implementations
impl RefUnwindSafe for ContentEncoding
impl Send for ContentEncoding
impl Sync for ContentEncoding
impl Unpin for ContentEncoding
impl UnwindSafe for ContentEncoding
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Error = <T as IntoHeaderValue>::Error
pub fn try_into_header_pair(
self
) -> Result<(HeaderName, HeaderValue), <T as IntoHeaderPair>::Error>
type Output = T
type Output = T
Should always be Self
pub fn vzip(self) -> V