code: public void weakAddWatcher(Path file, Listener watcher) {
          synchronized (mutex) {
              startWatchingInternal(file).add(new WeakReference<>(watcher)::get);
          }
      }
docs: Start watching file path and notify watcher for updates on that file.
  The watcher will be kept in a weak reference and will allow GC to delete
  the instance.
  
  @param file The file path to watch.
  @param watcher The watcher to be notified.