Trait aries_askar::Backend [−][src]
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
type Session: QueryBackend
type Session: QueryBackend
The type of session managed by this backend
Required methods
Create a new profile
fn get_profile_name(&self) -> &str
fn get_profile_name(&self) -> &str
Get the name of the active profile
Remove an existing profile
Create a Scan against the store
Create a new session against the store
fn rekey_backend(
&mut self,
method: StoreKeyMethod,
key: PassKey<'_>
) -> BoxFuture<'_, Result<(), Error>>
fn rekey_backend(
&mut self,
method: StoreKeyMethod,
key: PassKey<'_>
) -> BoxFuture<'_, Result<(), Error>>
Replace the wrapping key of the store