pub trait Backend: Send + Sync {
    type Session: QueryBackend;
    fn create_profile(
        &self,
        name: Option<String>
    ) -> BoxFuture<'_, Result<String, Error>>;
fn get_profile_name(&self) -> &str;
fn remove_profile(&self, name: String) -> BoxFuture<'_, Result<bool, Error>>;
fn scan(
        &self,
        profile: Option<String>,
        kind: EntryKind,
        category: String,
        tag_filter: Option<TagFilter>,
        offset: Option<i64>,
        limit: Option<i64>
    ) -> BoxFuture<'_, Result<Scan<'static, Entry>, Error>>;
fn session(
        &self,
        profile: Option<String>,
        transaction: bool
    ) -> Result<Self::Session, Error>;
fn rekey_backend(
        &mut self,
        method: StoreKeyMethod,
        key: PassKey<'_>
    ) -> BoxFuture<'_, Result<(), Error>>;
fn close(&self) -> BoxFuture<'_, Result<(), Error>>; }
Expand description

Represents a generic backend implementation

Associated Types

The type of session managed by this backend

Required methods

Create a new profile

Get the name of the active profile

Remove an existing profile

Create a Scan against the store

Create a new session against the store

Replace the wrapping key of the store

Close the store instance

Implementors