Struct websession::backingstore::FileBackingStore [−][src]
File based backing store.
Implementations
impl FileBackingStore
[src]
pub fn new(filename: &str) -> FileBackingStore
[src]
Create a new file based backing store with the given file. The file must already exist, and is assumed to have appropriate permissions.
pub fn new_with_cost(filename: &str, cost: u32) -> FileBackingStore
[src]
Create a new file based backing store with the given file. The file must already exist, and is assumed to have appropriate permissions.
Trait Implementations
impl BackingStore for FileBackingStore
[src]
fn encrypt_credentials(&self, plain: &str) -> Result<String, BackingStoreError>
[src]
fn get_credentials(
&self,
user: &str,
fail_if_locked: bool
) -> Result<String, BackingStoreError>
[src]
&self,
user: &str,
fail_if_locked: bool
) -> Result<String, BackingStoreError>
fn verify(
&self,
user: &str,
plain_cred: &str
) -> Result<bool, BackingStoreError>
[src]
&self,
user: &str,
plain_cred: &str
) -> Result<bool, BackingStoreError>
fn update_credentials(
&self,
user: &str,
enc_cred: &str
) -> Result<(), BackingStoreError>
[src]
&self,
user: &str,
enc_cred: &str
) -> Result<(), BackingStoreError>
fn lock(&self, user: &str) -> Result<(), BackingStoreError>
[src]
fn is_locked(&self, user: &str) -> Result<bool, BackingStoreError>
[src]
fn unlock(&self, user: &str) -> Result<(), BackingStoreError>
[src]
fn create_preencrypted(
&self,
user: &str,
enc_cred: &str
) -> Result<(), BackingStoreError>
[src]
&self,
user: &str,
enc_cred: &str
) -> Result<(), BackingStoreError>
fn delete(&self, user: &str) -> Result<(), BackingStoreError>
[src]
Returns Ok(()) on deletion, Err(BackingStoreError::NoSuchUser) if they were already deleted, or IO or Mutex errors.
fn users(&self) -> Result<Vec<String>, BackingStoreError>
[src]
fn check_user(&self, user: &str) -> Result<bool, BackingStoreError>
[src]
fn update_credentials_plain(
&self,
user: &str,
plain_cred: &str
) -> Result<(), BackingStoreError>
[src]
&self,
user: &str,
plain_cred: &str
) -> Result<(), BackingStoreError>
fn create_plain(
&self,
user: &str,
plain_cred: &str
) -> Result<(), BackingStoreError>
[src]
&self,
user: &str,
plain_cred: &str
) -> Result<(), BackingStoreError>
fn users_iter(&self) -> Result<IntoIter<String>, BackingStoreError>
[src]
impl Debug for FileBackingStore
[src]
Auto Trait Implementations
impl RefUnwindSafe for FileBackingStore
[src]
impl Send for FileBackingStore
[src]
impl Sync for FileBackingStore
[src]
impl Unpin for FileBackingStore
[src]
impl UnwindSafe for FileBackingStore
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,