#[non_exhaustive]pub enum TokenType {
Bearer,
}Expand description
The type of token, describing proper usage.
There is one other interesting type that is not yet formally specified: The MAC token,
see draft-ietf-oauth-v2-http-mac-02. The draft has long been expired but for the unlikely
case there are others, the enum exist. You might patch this to try out another token type
before proposing it for standardization.
In other context (RFC 8693) the explicitly non-access-token kind N_A also exists but this is
not a possible response.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Bearer
A bearer token used on its own in an Authorization header.
For this variant and its usage see RFC 6750.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TokenType
impl RefUnwindSafe for TokenType
impl Send for TokenType
impl Sync for TokenType
impl Unpin for TokenType
impl UnwindSafe for TokenType
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