Skip to main content

AuthStorageBackend

Trait AuthStorageBackend 

Source
pub trait AuthStorageBackend: Send + Sync {
    // Required methods
    fn read(&self) -> AuthResult<Option<String>>;
    fn write(&self, data: &str) -> AuthResult<()>;
    fn delete(&self) -> AuthResult<()>;
}
Expand description

Storage backend trait

Required Methods§

Source

fn read(&self) -> AuthResult<Option<String>>

Read stored data

Source

fn write(&self, data: &str) -> AuthResult<()>

Write data

Source

fn delete(&self) -> AuthResult<()>

Delete stored data

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§