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 Freeze for SessionContext
impl RefUnwindSafe for SessionContext
impl Send for SessionContext
impl Sync for SessionContext
impl Unpin for SessionContext
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