Trait PathsMut
trait PathsMut
Providing methods for adding and removing paths to watch.
Box<dyn PathsMut> is created by Watcher::paths_mut. See its documentation for more.
Required Methods
fn add(self: &mut Self, path: &Path, recursive_mode: RecursiveMode) -> Result<()>Add a new path to watch. See
Watcher::watchfor more.fn remove(self: &mut Self, path: &Path) -> Result<()>Remove a path from watching. See
Watcher::unwatchfor more.fn commit(self: Box<Self>) -> Result<()>Ensure added/removed paths are applied.
The behaviour of dropping a
PathsMutwithout callingcommitis unspecified. The implementation is free to ignore the changes or not, and may leave the watcher in a started or stopped state.