@ThreadSafe public class MFileCollectionManager extends CollectionManagerAbstract
CollectionAbstract.DateSorter, CollectionAbstract.MyStreamFilterCollectionManager.ChangeChecker, CollectionManager.TriggerEvent, CollectionManager.TriggerListener| Modifier and Type | Field and Description |
|---|---|
protected CollectionManager.ChangeChecker |
changeChecker
Deprecated.
Do not use
|
protected FeatureCollectionConfig |
config
Deprecated.
|
recheckauxInfo, CATALOG, collectionName, dateExtractor, DIR, FILE, GLOB, lastModified, LIST, logger, NCX_SUFFIX, protoChoice, root, sfilter, startCollection| Modifier | Constructor and Description |
|---|---|
|
MFileCollectionManager(FeatureCollectionConfig config,
java.util.Formatter errlog,
org.slf4j.Logger logger)
Deprecated.
|
|
MFileCollectionManager(java.lang.String name,
CollectionConfig mc,
CalendarDate startPartition,
org.slf4j.Logger logger)
Deprecated.
|
protected |
MFileCollectionManager(java.lang.String name,
org.slf4j.Logger logger)
Deprecated.
|
|
MFileCollectionManager(java.lang.String name,
java.lang.String spec,
java.util.Formatter errlog,
org.slf4j.Logger logger)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addDirectoryScan(java.lang.String dirName,
java.lang.String suffix,
java.lang.String regexpPatternString,
java.lang.String subdirsS,
java.lang.String olderS,
java.lang.Object auxInfo)
Deprecated.
Add a directory scan to the collection
|
static MController |
getController()
Deprecated.
|
java.lang.Iterable<MFile> |
getFilesSorted()
Deprecated.
Get the current collection of MFile.
|
long |
getLastChanged()
Deprecated.
Get the last time the collection changed
|
long |
getLastScanned()
Deprecated.
Get the last time scanned
|
long |
getOlderThanFilterInMSecs()
Deprecated.
|
boolean |
hasDateExtractor()
Deprecated.
Does this CollectionManager have the ability to extract a date from the MFile ?
|
protected boolean |
hasScans()
Deprecated.
|
boolean |
isScanNeeded()
Deprecated.
Compute if synchronous scan is needed.
|
static MFileCollectionManager |
open(java.lang.String collectionName,
java.lang.String collectionSpec,
java.lang.String olderThan,
java.util.Formatter errlog)
Deprecated.
|
static MFileCollectionManager |
openWithRecheck(java.lang.String collectionName,
java.lang.String recheckS)
Deprecated.
|
protected void |
reallyScan(java.util.Map<java.lang.String,MFile> map)
Deprecated.
|
boolean |
scan(boolean sendEvent)
Deprecated.
Scan the collection.
|
void |
setChangeChecker(CollectionManager.ChangeChecker strat)
Deprecated.
|
static void |
setController(MController _controller)
Deprecated.
Set the MController used by scan.
|
void |
setFiles(java.lang.Iterable<MFile> files)
Deprecated.
|
java.lang.String |
toString()
Deprecated.
|
addEventListener, close, createListenerManager, getFileIterator, getMetadata, getRecheck, isStatic, putMetadata, removeEventListener, scanIfNeeded, sendEvent, setMetadataStore, setStaticcleanName, extractDate, getAuxInfo, getCollectionName, getFilenames, getIndexFilename, getLastModified, getLatestFile, getPartitionDate, getProtoIndex, getRoot, makeFileListSorted, parseOlderThanString, putAuxInfo, setDateExtractor, setRoot, setStreamFilterclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitextractDate, getAuxInfo, getCollectionName, getFilenames, getIndexFilename, getLastModified, getLatestFile, getPartitionDate, getProtoIndex, getRoot, putAuxInfogetCollectionNameprotected FeatureCollectionConfig config
protected CollectionManager.ChangeChecker changeChecker
public MFileCollectionManager(FeatureCollectionConfig config, java.util.Formatter errlog, org.slf4j.Logger logger)
protected MFileCollectionManager(java.lang.String name,
org.slf4j.Logger logger)
public MFileCollectionManager(java.lang.String name,
java.lang.String spec,
java.util.Formatter errlog,
org.slf4j.Logger logger)
public MFileCollectionManager(java.lang.String name,
CollectionConfig mc,
CalendarDate startPartition,
org.slf4j.Logger logger)
public static void setController(MController _controller)
_controller - use this MControllerpublic static MController getController()
public static MFileCollectionManager open(java.lang.String collectionName, java.lang.String collectionSpec, java.lang.String olderThan, java.util.Formatter errlog) throws java.io.IOException
java.io.IOExceptionpublic static MFileCollectionManager openWithRecheck(java.lang.String collectionName, java.lang.String recheckS)
public void addDirectoryScan(java.lang.String dirName,
java.lang.String suffix,
java.lang.String regexpPatternString,
java.lang.String subdirsS,
java.lang.String olderS,
java.lang.Object auxInfo)
dirName - scan this directorysuffix - require this suffix (overriddden by regexp), may be nullregexpPatternString - if present, use this reqular expression to filter files , may be nullsubdirsS - if "true", descend into subdirectories, may be nullolderS - udunit time unit - files must be older than this amount of time (now - lastModified > olderTime), may be null
// * @param dateFormatString dateFormatMark string, may be nullauxInfo - attach this object to any MFile found by this scanpublic long getOlderThanFilterInMSecs()
public long getLastScanned()
CollectionManagerpublic long getLastChanged()
CollectionManagerprotected boolean hasScans()
public boolean isScanNeeded()
public void setChangeChecker(CollectionManager.ChangeChecker strat)
public boolean scan(boolean sendEvent)
throws java.io.IOException
CollectionManagerjava.io.IOException - on I/O errorpublic void setFiles(java.lang.Iterable<MFile> files)
public java.lang.Iterable<MFile> getFilesSorted()
MCollectionpublic boolean hasDateExtractor()
MCollectionhasDateExtractor in interface MCollectionhasDateExtractor in class CollectionAbstractprotected void reallyScan(java.util.Map<java.lang.String,MFile> map) throws java.io.IOException
java.io.IOExceptionpublic java.lang.String toString()
toString in class java.lang.Object