public class CollectionGlob extends CollectionAbstract
CollectionAbstract.DateSorter, CollectionAbstract.MyStreamFilterauxInfo, CATALOG, collectionName, dateExtractor, DIR, FILE, GLOB, lastModified, LIST, logger, NCX_SUFFIX, protoChoice, root, sfilter, startCollection| Constructor and Description |
|---|
CollectionGlob(String collectionName,
String glob,
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.
|
static java.nio.file.DirectoryStream |
newDirectoryStream(java.nio.file.Path dir,
String glob) |
cleanName, extractDate, getAuxInfo, getCollectionName, getFilenames, getIndexFilename, getLastModified, getLatestFile, getPartitionDate, getProtoIndex, getRoot, hasDateExtractor, makeFileListSorted, open, parseOlderThanString, putAuxInfo, setDateExtractor, setRoot, setStreamFilterpublic void close()
MCollectionpublic Iterable<MFile> getFilesSorted() throws IOException
MCollectionIOExceptionpublic CloseableIterator<MFile> getFileIterator() throws IOException
MCollection
try (CloseableIterator iter = getFileIterator()) {
while (iter.hasNext()) {
MFile file = iter.next();
}
}
IOExceptionpublic static java.nio.file.DirectoryStream newDirectoryStream(java.nio.file.Path dir, String glob) throws IOException
IOExceptionCopyright © 1999-2015 UCAR/Unidata. All Rights Reserved.