pub struct WatcherEventAdapter { /* private fields */ }Expand description
Converts watcher-specific path notifications into scanner cache work.
Implementations§
Source§impl WatcherEventAdapter
impl WatcherEventAdapter
Sourcepub fn new<I, S>(root: impl AsRef<Path>, ignore_files: I) -> Result<Self>
pub fn new<I, S>(root: impl AsRef<Path>, ignore_files: I) -> Result<Self>
Creates an adapter for an existing repository root.
§Errors
Returns an error when the root cannot be canonicalized or is not a directory.
Sourcepub fn with_options(
root: impl AsRef<Path>,
options: &ScanOptions,
) -> Result<Self>
pub fn with_options( root: impl AsRef<Path>, options: &ScanOptions, ) -> Result<Self>
Sourcepub fn plan<I>(&self, events: I) -> WatchPlanwhere
I: IntoIterator<Item = WatchEvent>,
pub fn plan<I>(&self, events: I) -> WatchPlanwhere
I: IntoIterator<Item = WatchEvent>,
Coalesces raw watcher events into a stable scanner invalidation plan.
Auto Trait Implementations§
impl Freeze for WatcherEventAdapter
impl RefUnwindSafe for WatcherEventAdapter
impl Send for WatcherEventAdapter
impl Sync for WatcherEventAdapter
impl Unpin for WatcherEventAdapter
impl UnsafeUnpin for WatcherEventAdapter
impl UnwindSafe for WatcherEventAdapter
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