Struct trillium_http_types::content::ContentLength [−][src]
pub struct ContentLength { /* fields omitted */ }Expand description
The size of the entity-body, in bytes, sent to the recipient.
Specifications
Examples
use http_types::Response; use http_types::content::{ContentLength}; let content_len = ContentLength::new(12); let mut res = Response::new(200); res.insert_header(&content_len, &content_len); let content_len = ContentLength::from_headers(res)?.unwrap(); assert_eq!(content_len.len(), 12);
Implementations
Trait Implementations
Access the header’s name.
Access the header’s value.
Auto Trait Implementations
impl RefUnwindSafe for ContentLengthimpl Send for ContentLengthimpl Sync for ContentLengthimpl Unpin for ContentLengthimpl UnwindSafe for ContentLength