pub struct SessionContext { /* private fields */ }Expand description
Example session-based authentication context
Implementations§
Trait Implementations§
Source§impl AuthenticationContext for SessionContext
impl AuthenticationContext for SessionContext
Source§fn get_user_id(&self) -> &Self::UserId
fn get_user_id(&self) -> &Self::UserId
Get the user ID from the authentication context
Source§fn get_granted_scopes(&self) -> Vec<String>
fn get_granted_scopes(&self) -> Vec<String>
Get any granted scopes from the authentication context
These are typically permissions granted directly via tokens
Source§fn get_context(&self) -> &Self::ContextData
fn get_context(&self) -> &Self::ContextData
Get additional context data
Auto Trait Implementations§
impl Forget for SessionContext
impl Freeze for SessionContextwhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<String>: Freeze,
PhantomData<(String, String)>: Freeze,
impl Move for SessionContext
impl RefUnwindSafe for SessionContext
impl Send for SessionContext
impl Sync for SessionContext
impl Unpin for SessionContext
impl UnsafeUnpin for SessionContextwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
PhantomData<(String, String)>: UnsafeUnpin,
impl UnwindSafe for SessionContext
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