Class DeleteChecker

    • Constructor Detail

      • DeleteChecker

        protected DeleteChecker​(SyncEndpoint syncEndpoint,
                                String spaceId,
                                List<File> syncDirs,
                                String prefix)
        Creates a delete checker
        Parameters:
        syncEndpoint - the endpoint to which files are synced
        syncDirs - the list of local source directories being synced
    • Method Detail

      • run

        public void run()
        Checks each item in the list of files stored at the endpoint (relative file paths) against each sync directory to see if there is a matching local file. If there is no matching file, that means that the file which exists in the endpoint no longer exists in the local source directories (i.e. the source file has been deleted.) Each file of this type is removed from the endpoint. Note that if a prefix is used, all files in the endpoint that do not have the prefix will be removed (as they cannot be consistent with what the content ID will be for files pushed up with the prefix.)
        Specified by:
        run in interface Runnable
      • checkComplete

        public boolean checkComplete()
      • stop

        public void stop()