Class AsyncIndexer

  • All Implemented Interfaces:
    java.lang.Runnable

    public class AsyncIndexer
    extends java.lang.Object
    implements java.lang.Runnable
    AsyncIndexer provides a Runnable to start as a separate thread. Running this will result in the list of files provided being indexed and deduped. The result of this indexation will be captured in DatabaseVersions, which will be stored in the provided Queue, which must be threadsafe.
    • Constructor Summary

      Constructors 
      Constructor Description
      AsyncIndexer​(Config config, Deduper deduper, java.util.List<java.io.File> files, java.util.List<java.io.File> deletedFiles, java.util.Queue<DatabaseVersion> queue)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void run()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AsyncIndexer

        public AsyncIndexer​(Config config,
                            Deduper deduper,
                            java.util.List<java.io.File> files,
                            java.util.List<java.io.File> deletedFiles,
                            java.util.Queue<DatabaseVersion> queue)
        Parameters:
        config - specifying all necessary options
        deduper - the Deduper, already configured.
        files - List of Files to be indexed.
        queue - a threadsafe Queue to communicate DatabaseVersions.
    • Method Detail

      • run

        public void run()
        Specified by:
        run in interface java.lang.Runnable