Class FileWatcher
java.lang.Object
me.lucko.luckperms.common.storage.implementation.file.watcher.AbstractFileWatcher
me.lucko.luckperms.common.storage.implementation.file.watcher.FileWatcher
- All Implemented Interfaces:
AutoCloseable
Simple implementation of
AbstractFileWatcher for LuckPerms data files.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classEncapsulates a "watcher" in a specific directory. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetWatcher(Path path) Gets aFileWatcher.WatchedLocationinstance for a given path.protected voidprocessEvent(WatchEvent<Path> event, Path path) Process an observed watch event.Methods inherited from class me.lucko.luckperms.common.storage.implementation.file.watcher.AbstractFileWatcher
close, register, registerRecursively, runEventProcessingLoop
-
Constructor Details
-
FileWatcher
- Throws:
IOException
-
-
Method Details
-
getWatcher
Gets aFileWatcher.WatchedLocationinstance for a given path.- Parameters:
path- the path to get a watcher for- Returns:
- the watched location
-
processEvent
Description copied from class:AbstractFileWatcherProcess an observed watch event.- Specified by:
processEventin classAbstractFileWatcher- Parameters:
event- the eventpath- the resolved event context
-