typed_headers/impls/
content_encoding.rs

1use http::header::CONTENT_ENCODING;
2
3use super::ContentCoding;
4
5header! {
6    /// `Content-Encoding` header, defined in
7    /// [RFC7231](http://tools.ietf.org/html/rfc7231#section-3.1.2.2)
8    ///
9    /// The `Content-Encoding` header field indicates what content codings
10    /// have been applied to the representation, beyond those inherent in the
11    /// media type, and thus what decoding mechanisms have to be applied in
12    /// order to obtain data in the media type referenced by the Content-Type
13    /// header field.  Content-Encoding is primarily used to allow a
14    /// representation's data to be compressed without losing the identity of
15    /// its underlying media type.
16    ///
17    /// # ABNF
18    ///
19    /// ```text
20    /// Content-Encoding = 1#content-coding
21    /// ```
22    ///
23    /// # Example values
24    ///
25    /// * `gzip`
26    (ContentEncoding, CONTENT_ENCODING) => (ContentCoding)+
27}