pub struct FileStorageStrategy {
pub format: FormatStrategy,
pub atomic_write: AtomicWriteConfig,
pub load_behavior: LoadBehavior,
}Expand description
Strategy for file storage operations.
Fields§
§format: FormatStrategyFile format to use
atomic_write: AtomicWriteConfigAtomic write configuration
load_behavior: LoadBehaviorBehavior when file doesn’t exist
Implementations§
Source§impl FileStorageStrategy
impl FileStorageStrategy
Sourcepub fn with_format(self, format: FormatStrategy) -> Self
pub fn with_format(self, format: FormatStrategy) -> Self
Set the file format.
Sourcepub fn with_retry_count(self, count: usize) -> Self
pub fn with_retry_count(self, count: usize) -> Self
Set the retry count for atomic writes.
Sourcepub fn with_cleanup(self, cleanup: bool) -> Self
pub fn with_cleanup(self, cleanup: bool) -> Self
Set whether to cleanup temporary files.
Sourcepub fn with_load_behavior(self, behavior: LoadBehavior) -> Self
pub fn with_load_behavior(self, behavior: LoadBehavior) -> Self
Set the load behavior.
Trait Implementations§
Source§impl Clone for FileStorageStrategy
impl Clone for FileStorageStrategy
Source§fn clone(&self) -> FileStorageStrategy
fn clone(&self) -> FileStorageStrategy
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileStorageStrategy
impl Debug for FileStorageStrategy
Auto Trait Implementations§
impl Freeze for FileStorageStrategy
impl RefUnwindSafe for FileStorageStrategy
impl Send for FileStorageStrategy
impl Sync for FileStorageStrategy
impl Unpin for FileStorageStrategy
impl UnwindSafe for FileStorageStrategy
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