pub struct JWTBuilder<T: Serialize> { /* private fields */ }Implementations§
Source§impl<T: Serialize> JWTBuilder<T>
impl<T: Serialize> JWTBuilder<T>
pub fn new(data: T) -> Self
pub fn iss(self, iss: String) -> Self
pub fn exp(self, exp: DateTime<Utc>) -> Self
pub fn sub(self, sub: String) -> Self
pub fn aud(self, aud: String) -> Self
pub fn nbf(self, nbf: DateTime<Utc>) -> Self
pub fn iat(self, iat: DateTime<Utc>) -> Self
pub fn jti(self, jti: u64) -> Self
pub fn build(self, alg: Algorithm, key: &EncodingKey) -> TokenResult<String>
Auto Trait Implementations§
impl<T> Freeze for JWTBuilder<T>where
T: Freeze,
impl<T> RefUnwindSafe for JWTBuilder<T>where
T: RefUnwindSafe,
impl<T> Send for JWTBuilder<T>where
T: Send,
impl<T> Sync for JWTBuilder<T>where
T: Sync,
impl<T> Unpin for JWTBuilder<T>where
T: Unpin,
impl<T> UnwindSafe for JWTBuilder<T>where
T: UnwindSafe,
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