pub struct SessionRevoker<R> { /* private fields */ }Expand description
Service that revokes session state during logout flows.
§Examples
use webgates_sessions::services::SessionRevoker;
// Create a revoker from any SessionRepository implementation.
let revoker = SessionRevoker::new(Noop);Implementations§
Source§impl<R> SessionRevoker<R>
impl<R> SessionRevoker<R>
Source§impl<R> SessionRevoker<R>where
R: SessionRepository,
impl<R> SessionRevoker<R>where
R: SessionRepository,
Sourcepub async fn revoke_session(
&self,
request: LogoutRequest,
) -> Result<LogoutOutcome>
pub async fn revoke_session( &self, request: LogoutRequest, ) -> Result<LogoutOutcome>
Revokes the session state targeted by request.
§Errors
Returns a session error when the repository revocation operation fails.
Trait Implementations§
Source§impl<R: Clone> Clone for SessionRevoker<R>
impl<R: Clone> Clone for SessionRevoker<R>
Source§fn clone(&self) -> SessionRevoker<R>
fn clone(&self) -> SessionRevoker<R>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl<R> Freeze for SessionRevoker<R>where
R: Freeze,
impl<R> RefUnwindSafe for SessionRevoker<R>where
R: RefUnwindSafe,
impl<R> Send for SessionRevoker<R>where
R: Send,
impl<R> Sync for SessionRevoker<R>where
R: Sync,
impl<R> Unpin for SessionRevoker<R>where
R: Unpin,
impl<R> UnsafeUnpin for SessionRevoker<R>where
R: UnsafeUnpin,
impl<R> UnwindSafe for SessionRevoker<R>where
R: 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