pub trait WatcherHandler {
// Required methods
async fn on_snapshot(
&self,
snapshot: Snapshot,
state: State,
) -> Result<(), Error>;
async fn on_error(&self, error: Error);
}
Expand description
A simple file watcher that monitors changes in a list of files and triggers appropriate handlers.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.