Enum notify::DebouncedEvent[][src]

pub enum DebouncedEvent {
    NoticeWrite(PathBuf),
    NoticeRemove(PathBuf),
    Create(PathBuf),
    Write(PathBuf),
    Chmod(PathBuf),
    Remove(PathBuf),
    Rename(PathBufPathBuf),
    Rescan,
    Error(ErrorOption<PathBuf>),
}
Expand description

Event delivered when action occurs on a watched path in debounced mode

Variants

NoticeWrite(PathBuf)
Expand description

NoticeWrite is emitted immediately after the first write event for the path.

If you are reading from that file, you should probably close it immediately and discard all data you read from it.

NoticeRemove(PathBuf)
Expand description

NoticeRemove is emitted immediately after a remove or rename event for the path.

The file will continue to exist until its last file handle is closed.

Create(PathBuf)
Expand description

Create is emitted when a file or directory has been created and no events were detected for the path within the specified time frame.

Create events have a higher priority than Write and Chmod. These events will not be emitted if they are detected before the Create event has been emitted.

Write(PathBuf)
Expand description

Write is emitted when a file has been written to and no events were detected for the path within the specified time frame.

Write events have a higher priority than Chmod. Chmod will not be emitted if it’s detected before the Write event has been emitted.

Upon receiving a Create event for a directory, it is necessary to scan the newly created directory for contents. The directory can contain files or directories if those contents were created before the directory could be watched, or if the directory was moved into the watched directory.

Chmod(PathBuf)
Expand description

Chmod is emitted when attributes have been changed and no events were detected for the path within the specified time frame.

Remove(PathBuf)
Expand description

Remove is emitted when a file or directory has been removed and no events were detected for the path within the specified time frame.

Rename(PathBufPathBuf)
Expand description

Rename is emitted when a file or directory has been moved within a watched directory and no events were detected for the new path within the specified time frame.

The first path contains the source, the second path the destination.

Rescan
Expand description

Rescan is emitted immediately after a problem has been detected that makes it necessary to re-scan the watched directories.

Error(ErrorOption<PathBuf>)
Expand description

Error is emitted immediately after a error has been detected.

This event may contain a path for which the error was detected.

Trait Implementations

impl Debug for DebouncedEvent[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl PartialEq<DebouncedEvent> for DebouncedEvent[src]

fn eq(&self, other: &DebouncedEvent) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.