pub struct AuthorizedSession { /* private fields */ }Expand description
Session that passed one AdminPermissionApi::authorize_request check.
Only that method creates this value. It holds the user and session read from the store for that check. Use it for the operation that requested the check. Do not cache it: a later revocation or role change does not update it.
Implementations§
Source§impl AuthorizedSession
impl AuthorizedSession
Sourcepub fn session(&self) -> &SessionView
pub fn session(&self) -> &SessionView
Session that authenticated the request.
Sourcepub fn into_parts(self) -> (UserView, SessionView)
pub fn into_parts(self) -> (UserView, SessionView)
Return the user and the session.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AuthorizedSession
impl RefUnwindSafe for AuthorizedSession
impl Send for AuthorizedSession
impl Sync for AuthorizedSession
impl Unpin for AuthorizedSession
impl UnsafeUnpin for AuthorizedSession
impl UnwindSafe for AuthorizedSession
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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