[−][src]Struct twilio_async::Authorization
Authorization header, defined in RFC7235
The Authorization header field allows a user agent to authenticate
itself with an origin server -- usually, but not necessarily, after
receiving a 401 (Unauthorized) response. Its value consists of
credentials containing the authentication information of the user
agent for the realm of the resource being requested.
ABNF
Authorization = credentials
Example values
Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==Bearer fpKL54jvWmEGVoRdCNjG
Methods from Deref<Target = Credentials>
pub fn scheme(&self) -> &AuthScheme[src]
Returns the auth-scheme associated with the credentials.
pub fn token68(&self) -> Option<&Token68>[src]
Returns the token68 value associated with the credentials if present.
pub fn as_bearer(&self) -> Option<&Token68>[src]
Returns the bearer token if this contains Bearer credentials.
Trait Implementations
impl Clone for Authorization[src]
fn clone(&self) -> Authorization[src]
fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Debug for Authorization[src]
impl Deref for Authorization[src]
type Target = Credentials
The resulting type after dereferencing.
fn deref(&self) -> &Credentials[src]
impl DerefMut for Authorization[src]
fn deref_mut(&mut self) -> &mut Credentials[src]
impl Header for Authorization[src]
fn name() -> &'static HeaderName[src]
fn from_values(
values: &mut ValueIter<HeaderValue>
) -> Result<Option<Authorization>, Error>[src]
values: &mut ValueIter<HeaderValue>
) -> Result<Option<Authorization>, Error>
fn to_values(&self, values: &mut ToValues)[src]
impl PartialEq<Authorization> for Authorization[src]
fn eq(&self, other: &Authorization) -> bool[src]
fn ne(&self, other: &Authorization) -> bool[src]
impl StructuralPartialEq for Authorization[src]
Auto Trait Implementations
impl RefUnwindSafe for Authorization
impl Send for Authorization
impl Sync for Authorization
impl Unpin for Authorization
impl UnwindSafe for Authorization
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T[src]
fn clone_into(&self, target: &mut T)[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,