pub struct UserAgent;Expand description
See USER_AGENT for more details.
Implementations§
Source§impl UserAgent
impl UserAgent
Sourcepub const fn from_static(value: &'static str) -> Header<UserAgent>
pub const fn from_static(value: &'static str) -> Header<UserAgent>
Creates a new instance of [Header<T>] from a static str
Sourcepub fn from_bytes(bytes: &[u8]) -> Result<Header<UserAgent>, Error>
pub fn from_bytes(bytes: &[u8]) -> Result<Header<UserAgent>, Error>
Construct a typed header from bytes (validated).
Sourcepub fn new(value: HeaderValue) -> Header<UserAgent>
pub fn new(value: HeaderValue) -> Header<UserAgent>
Wrap an owned raw HeaderValue (validated elsewhere).
Sourcepub fn from_ref(value: &HeaderValue) -> Header<UserAgent>
pub fn from_ref(value: &HeaderValue) -> Header<UserAgent>
Wrap a borrowed raw HeaderValue (validated elsewhere).
Trait Implementations§
Source§impl FromHeaders for UserAgent
impl FromHeaders for UserAgent
Source§const NAME: HeaderName = USER_AGENT
const NAME: HeaderName = USER_AGENT
Returns current
HeaderNameSource§fn from_headers(headers: &HeaderMap) -> Option<&HeaderValue>
fn from_headers(headers: &HeaderMap) -> Option<&HeaderValue>
Reads a
HeaderValue from HeaderMapSource§impl Ord for UserAgent
impl Ord for UserAgent
Source§impl PartialOrd for UserAgent
impl PartialOrd for UserAgent
impl Copy for UserAgent
impl Eq for UserAgent
impl StructuralPartialEq for UserAgent
Auto Trait Implementations§
impl Freeze for UserAgent
impl RefUnwindSafe for UserAgent
impl Send for UserAgent
impl Sync for UserAgent
impl Unpin for UserAgent
impl UnsafeUnpin for UserAgent
impl UnwindSafe for UserAgent
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.