public FileWatcher(path as Path, pollIntervalMs as Int = 50):
Creates a watcher for a Path instance.
| Parameter | Description |
|---|---|
path | File path to watch. |
pollIntervalMs | Polling interval in milliseconds. |
watcher = FileWatcher(Path.tempDir.resolve("app.log"), 500)