Expand description
§Example
use http::header::{HeaderMap, HeaderValue, ACCEPT_ENCODING};
let mut headers = HeaderMap::new();
headers.insert(ACCEPT_ENCODING, HeaderValue::from_str("gzip, deflate, br")?);
let encoding = accept_encoding::parse(&headers)?;
assert!(encoding.is_brotli());
Structs§
Enums§
Functions§
- parse
- Parse a set of HTTP headers into an
Encoding
.