Last active
January 12, 2017 19:12
-
-
Save ldclakmal/03b63f0a1da872262a77f0ee136f4d73 to your computer and use it in GitHub Desktop.
Create a watch key and poll the events
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WatchKey key = watcher.take(); | |
for (WatchEvent<?> event: key.pollEvents()) { | |
WatchEvent.Kind<?> kind = event.kind(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment