Lines Matching defs:dir
66 private void register(Path dir) throws IOException {
67 WatchKey key = dir.register(watcher, ENTRY_CREATE, ENTRY_DELETE, ENTRY_MODIFY);
70 System.out.format("register: %s\n", dir);
81 public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs)
84 register(dir);
93 WatchDir(Path dir, boolean recursive) throws IOException {
98 System.out.format("Scanning %s ...\n", dir);
99 registerAll(dir);
102 register(dir);
164 System.err.println("usage: java WatchDir [-r] dir");
182 Path dir = Paths.get(args[dirArg]);
183 new WatchDir(dir, recursive).processEvents();