Trait rustls::StoresServerSessions
[−]
[src]
pub trait StoresServerSessions { fn generate(&self) -> SessionID; fn put(&mut self, id: &SessionID, value: Vec<u8>) -> bool; fn get(&self, id: &SessionID) -> Option<Vec<u8>>; fn del(&mut self, id: &SessionID) -> bool; }
Required Methods
fn generate(&self) -> SessionID
Generate a session ID.
fn put(&mut self, id: &SessionID, value: Vec<u8>) -> bool
Store session secrets encoded in value
against key id
,
overwrites any existing value against id
. Returns true
if the value was stored.
fn get(&self, id: &SessionID) -> Option<Vec<u8>>
Find a session with the given id
. Return it, or None
if it doesn't exist.
fn del(&mut self, id: &SessionID) -> bool
Erase a session with the given id
. Return true if
id
existed and was removed.
Implementors
impl StoresServerSessions for ServerSessionMemoryCache