pub struct DirCacheOpts {
pub mem_pull_opt: MemPullOpt,
pub mem_push_opt: MemPushOpt,
pub generation_opt: GenerationOpt,
pub sync_opt: SyncOpt,
}Expand description
Options for controlling the behavior of operations on a DirCache.
See the specific options for more details
Fields§
§mem_pull_opt: MemPullOpt§mem_push_opt: MemPushOpt§generation_opt: GenerationOpt§sync_opt: SyncOptImplementations§
Source§impl DirCacheOpts
impl DirCacheOpts
pub const fn new( mem_pull_opt: MemPullOpt, mem_push_opt: MemPushOpt, generation_opt: GenerationOpt, sync_opt: SyncOpt, ) -> Self
pub const fn with_mem_pull_opt(self, mem_pull_opt: MemPullOpt) -> Self
pub const fn with_mem_push_opt(self, mem_push_opt: MemPushOpt) -> Self
pub const fn with_generation_opt(self, generation_opt: GenerationOpt) -> Self
pub const fn with_sync_opt(self, sync_opt: SyncOpt) -> Self
Sourcepub fn open(
self,
path: &Path,
cache_open_options: CacheOpenOptions,
) -> Result<DirCache>
pub fn open( self, path: &Path, cache_open_options: CacheOpenOptions, ) -> Result<DirCache>
Use these DirCacheOpts to open a DirCache.
§Errors
Depending on the open options a directory already being present or not may cause failure.
Various io-errors, from creating the DirCache.
Trait Implementations§
Source§impl Clone for DirCacheOpts
impl Clone for DirCacheOpts
Source§fn clone(&self) -> DirCacheOpts
fn clone(&self) -> DirCacheOpts
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 DirCacheOpts
impl Debug for DirCacheOpts
Source§impl Default for DirCacheOpts
impl Default for DirCacheOpts
Source§fn default() -> DirCacheOpts
fn default() -> DirCacheOpts
Returns the “default value” for a type. Read more
impl Copy for DirCacheOpts
Auto Trait Implementations§
impl Freeze for DirCacheOpts
impl RefUnwindSafe for DirCacheOpts
impl Send for DirCacheOpts
impl Sync for DirCacheOpts
impl Unpin for DirCacheOpts
impl UnwindSafe for DirCacheOpts
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