public class PartitionManagerFromIndexDirectory extends CollectionAbstract implements PartitionManager
CollectionAbstract.DateSorter, CollectionAbstract.MyGribFilterauxInfo, CATALOG, collectionName, dateExtractor, DIR, FILE, filter, GLOB, lastModified, LIST, logger, NCX_SUFFIX, protoChoice, root, sfilter, startCollection| Constructor and Description |
|---|
PartitionManagerFromIndexDirectory(String name,
FeatureCollectionConfig config,
File directory,
org.slf4j.Logger logger) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close and release any resources.
|
CloseableIterator<MFile> |
getFileIterator()
Get the current collection of MFile, no guaranteed order.
|
Iterable<MFile> |
getFilesSorted()
Get the current collection of MFile.
|
boolean |
isLeaf()
Consider MCollections as a tree.
|
Iterable<MCollection> |
makePartitions(CollectionUpdateType forceCollection) |
cleanName, extractDate, getAuxInfo, getCollectionName, getFilenames, getIndexFilename, getLastModified, getLatestFile, getProtoIndex, getRoot, getStartCollection, hasDateExtractor, makeFileListSorted, open, parseOlderThanString, putAuxInfo, setDateExtractor, setLeaf, setMFileFilter, setRoot, setStreamFilterclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitextractDate, getAuxInfo, getCollectionName, getFilenames, getIndexFilename, getLastModified, getLatestFile, getProtoIndex, getRoot, getStartCollection, hasDateExtractor, putAuxInfopublic PartitionManagerFromIndexDirectory(String name, FeatureCollectionConfig config, File directory, org.slf4j.Logger logger)
public Iterable<MCollection> makePartitions(CollectionUpdateType forceCollection) throws IOException
makePartitions in interface PartitionManagerIOExceptionpublic void close()
MCollectionclose in interface AutoCloseableclose in interface MCollectionpublic boolean isLeaf()
MCollectionisLeaf in interface MCollectionisLeaf in class CollectionAbstractpublic Iterable<MFile> getFilesSorted() throws IOException
MCollectiongetFilesSorted in interface MCollectionIOExceptionpublic CloseableIterator<MFile> getFileIterator() throws IOException
MCollection
try (CloseableIterator iter = getFileIterator()) {
while (iter.hasNext()) {
MFile file = iter.next();
}
}
getFileIterator in interface MCollectionIOExceptionCopyright © 1999–2015 UCAR/Unidata. All rights reserved.