pub trait SessionStore: Send {
type Session;
type Key: SessionKey;
// Required methods
fn create_session<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(Self::Key, Self::Session)>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn load_session<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 Self::Key,
) -> Pin<Box<dyn Future<Output = Result<Option<Self::Session>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Required Associated Types§
type Session
type Key: SessionKey
Required Methods§
fn create_session<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(Self::Key, Self::Session)>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn load_session<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 Self::Key,
) -> Pin<Box<dyn Future<Output = Result<Option<Self::Session>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".