pub struct FileMetadataCache {
pub files: HashMap<PathBuf, FileSnapshot>,
pub last_scan_time: u64,
}Expand description
Tracks file metadata for change detection
Fields§
§files: HashMap<PathBuf, FileSnapshot>§last_scan_time: u64Implementations§
Source§impl FileMetadataCache
impl FileMetadataCache
pub fn new() -> Self
pub fn load_or_create(cache_path: &Path) -> Result<Self>
pub fn read_from_file(path: &Path) -> Result<Self>
pub fn write_to_file(&self, path: &Path) -> Result<()>
pub fn update_scan_time(&mut self)
Trait Implementations§
Source§impl Clone for FileMetadataCache
impl Clone for FileMetadataCache
Source§fn clone(&self) -> FileMetadataCache
fn clone(&self) -> FileMetadataCache
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 FileMetadataCache
impl Debug for FileMetadataCache
Source§impl<'de> Deserialize<'de> for FileMetadataCache
impl<'de> Deserialize<'de> for FileMetadataCache
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for FileMetadataCache
impl RefUnwindSafe for FileMetadataCache
impl Send for FileMetadataCache
impl Sync for FileMetadataCache
impl Unpin for FileMetadataCache
impl UnwindSafe for FileMetadataCache
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