Struct simple_fs::DebouncedEvent
source · pub struct DebouncedEvent {
pub event: Event,
pub time: Instant,
}
Expand description
A debounced event is emitted after a short delay.
Fields§
§event: Event
The original event.
time: Instant
The time at which the event occurred.
Implementations§
source§impl DebouncedEvent
impl DebouncedEvent
pub fn new(event: Event, time: Instant) -> DebouncedEvent
Methods from Deref<Target = Event>§
sourcepub fn need_rescan(&self) -> bool
pub fn need_rescan(&self) -> bool
Returns whether some events may have been missed. If true, you should assume any file or folder might have been modified.
See Flag::Rescan
for more information.
sourcepub fn tracker(&self) -> Option<usize>
pub fn tracker(&self) -> Option<usize>
Retrieves the tracker ID for an event directly, if present.
sourcepub fn flag(&self) -> Option<Flag>
pub fn flag(&self) -> Option<Flag>
Retrieves the Notify flag for an event directly, if present.
Trait Implementations§
source§impl Clone for DebouncedEvent
impl Clone for DebouncedEvent
source§fn clone(&self) -> DebouncedEvent
fn clone(&self) -> DebouncedEvent
Returns a copy 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 DebouncedEvent
impl Debug for DebouncedEvent
source§impl Default for DebouncedEvent
impl Default for DebouncedEvent
source§fn default() -> DebouncedEvent
fn default() -> DebouncedEvent
Returns the “default value” for a type. Read more
source§impl Deref for DebouncedEvent
impl Deref for DebouncedEvent
source§impl DerefMut for DebouncedEvent
impl DerefMut for DebouncedEvent
source§impl From<Event> for DebouncedEvent
impl From<Event> for DebouncedEvent
source§fn from(event: Event) -> DebouncedEvent
fn from(event: Event) -> DebouncedEvent
Converts to this type from the input type.
source§impl PartialEq for DebouncedEvent
impl PartialEq for DebouncedEvent
source§fn eq(&self, other: &DebouncedEvent) -> bool
fn eq(&self, other: &DebouncedEvent) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for DebouncedEvent
impl StructuralPartialEq for DebouncedEvent
Auto Trait Implementations§
impl RefUnwindSafe for DebouncedEvent
impl Send for DebouncedEvent
impl Sync for DebouncedEvent
impl Unpin for DebouncedEvent
impl UnwindSafe for DebouncedEvent
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