pub struct FileBackend { /* private fields */ }Implementations§
Source§impl FileBackend
impl FileBackend
pub fn new( root: PathBuf, history: StoreHistory, settings: StorageStateSettings, ) -> Self
pub fn with_journal_opener( root: PathBuf, history: StoreHistory, settings: StorageStateSettings, opener: impl Fn(&Path) -> Result<File> + Send + Sync + 'static, ) -> Self
Trait Implementations§
Source§impl StateBackend for FileBackend
impl StateBackend for FileBackend
fn history(&self) -> &StoreHistory
fn open(&self) -> StorageFuture<'_, RecoveryPosition>
fn read_snapshot( &self, maximum: NonZeroUsize, ) -> StorageFuture<'_, Option<RecoverySnapshot>>
fn write_snapshot<'a>( &'a self, snapshot: &'a RecoverySnapshot, ) -> StorageFuture<'a, ()>
fn read_entries<'a>( &'a self, after: &'a RecoveryPosition, through: &'a RecoveryPosition, limits: ReadLimits, ) -> StorageFuture<'a, RecoveryPage>
fn write_entries<'a>( &'a self, entries: &'a [RecoveryEntry], ) -> StorageFuture<'a, ()>
fn flush<'a>( &'a self, through: &'a RecoveryPosition, ) -> StorageFuture<'a, RecoveryPosition>
fn close(&self) -> StorageFuture<'_, ()>
Auto Trait Implementations§
impl !RefUnwindSafe for FileBackend
impl !UnwindSafe for FileBackend
impl Freeze for FileBackend
impl Send for FileBackend
impl Sync for FileBackend
impl Unpin for FileBackend
impl UnsafeUnpin for FileBackend
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more