Struct jsonwebtoken_google_wasm::Parser
source · pub struct Parser { /* private fields */ }
Implementations§
source§impl Parser
impl Parser
pub const GOOGLE_CERT_URL: &'static str = "https://www.googleapis.com/oauth2/v3/certs"
pub fn new(client_id: &str) -> Self
pub fn new_with_custom_cert_url(client_id: &str, public_key_url: &str) -> Self
sourcepub async fn parse<T: DeserializeOwned>(
&mut self,
token: &str
) -> Result<T, ParserError>
pub async fn parse<T: DeserializeOwned>( &mut self, token: &str ) -> Result<T, ParserError>
Parses and validates the provided token. Validation is done against the associated DecodingKey for the kid of the token, fetched from the key_provider (google).
Auto Trait Implementations§
impl !RefUnwindSafe for Parser
impl Send for Parser
impl !Sync for Parser
impl Unpin for Parser
impl !UnwindSafe for Parser
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