Class CollectionManagerCatalog

    • Constructor Detail

      • CollectionManagerCatalog

        public CollectionManagerCatalog​(String collectionName,
                                        String collectionSpec,
                                        String olderThan,
                                        Formatter errlog)
    • Method Detail

      • isScanNeeded

        public boolean isScanNeeded()
        Description copied from interface: CollectionManager
        Compute whether rescan is needed, based on getRecheck(), and the LastScanned value.
        Specified by:
        isScanNeeded in interface CollectionManager
        Returns:
        true if rescan is needed.
      • scan

        public boolean scan​(boolean sendEvent)
                     throws IOException
        Description copied from interface: CollectionManager
        Scan the collection. Files may have been deleted or added since last time. If the MFile already exists in the current list, leave it in the list. If anything changes, send TriggerEvent(TriggerType.update) and return true Get the results from getFiles()
        Specified by:
        scan in interface CollectionManager
        Returns:
        true if anything actually changed.
        Throws:
        IOException - on I/O error
      • getFilesSorted

        public Iterable<MFile> getFilesSorted()
        Description copied from interface: MCollection
        Get the current collection of MFile. if hasDateExtractor() == true, these will be sorted by Date, otherwise by path.
        Specified by:
        getFilesSorted in interface MCollection
        Returns:
        current collection of MFile as an Iterable.