List of usage examples for java.nio.file StandardWatchEventKinds ENTRY_DELETE
WatchEvent.Kind ENTRY_DELETE
To view the source code for java.nio.file StandardWatchEventKinds ENTRY_DELETE.
Click Source Link
From source file:org.siphon.db2js.jshttp.ServerUnitManager.java
public void onFileChanged(WatchEvent<Path> ev, Path file) { Kind<Path> kind = ev.kind(); String filename = file.toString(); if (kind == StandardWatchEventKinds.ENTRY_DELETE) { if (contexts.containsKey(filename)) { if (logger.isDebugEnabled()) { logger.debug(filename + " dropped"); }// w w w .ja v a 2 s.c om contexts.remove(filename); } } else if (kind == StandardWatchEventKinds.ENTRY_MODIFY) { if (contexts.containsKey(filename)) { if (logger.isDebugEnabled()) { logger.debug(filename + " changed"); } contexts.remove(filename); } } }