pub struct Headers { /* private fields */ }
Expand description
The HTTP header map. All the names are not case sensitive.
§Example
let mut headers = mini_async_http::Headers::new();
assert!(headers.get_header("missing").is_none());
headers.set_header("Content-type","text/plain");
assert_eq!(headers.get_header("content-type").unwrap(),"text/plain");
headers.set_header("Content-type","application/json");
assert_eq!(headers.get_header("content-type").unwrap(),"application/json");
Implementations§
Trait Implementations§
Source§impl IntoIterator for Headers
impl IntoIterator for Headers
Auto Trait Implementations§
impl Freeze for Headers
impl RefUnwindSafe for Headers
impl Send for Headers
impl Sync for Headers
impl Unpin for Headers
impl UnwindSafe for Headers
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more