Class WatchQueueReader

  • All Implemented Interfaces:

    public class WatchQueueReader
    extends Object
    implements Runnable
    Base class for watch queue readers
    Fabio Marini - Initial contribution, Dimitar Ivanov - use relative path in watch events. Added option to watch directory events or not, Ana Dimova - reduce to a single watch thread for all class instances of AbstractWatchService
    • Field Detail

      • logger

        protected final org.slf4j.Logger logger
    • Method Detail

      • customizeWatchQueueReader

        protected void customizeWatchQueueReader​(AbstractWatchService watchService,
                                                 Path toWatch,
                                                 boolean watchSubDirectories)
        Customize the queue reader to process the watch events for the given directory, provided by the watch service
        watchService - the watch service, requesting the watch events for the watched directory
        toWatch - the directory being watched by the watch service
        watchSubDirectories - a boolean flag that specifies if the child directories of the registered directory will being watched by the watch service
      • run

        public void run()
        Specified by:
        run in interface Runnable