@ThreadSafe
public class CollectionSpecParser
extends java.lang.Object
the idea is that one copies the full path of an example dataset, then edits it
Example: "/data/ldm/pub/native/grid/NCEP/GFS/Alaska_191km/** /GFS_Alaska_191km_#yyyyMMdd_HHmm#\.grib1$"
Example: "Q:/grid/grib/grib1/data/agg/.*\.grb"
Constructor and Description |
---|
CollectionSpecParser(java.lang.String collectionSpec,
java.util.Formatter errlog)
Single spec : "/topdir/** /#dateFormatMark#regExp"
This only allows the dateFormatMark to be in the file name, not anywhere else in the filename path,
and you cant use any part of the dateFormat to filter on.
|
CollectionSpecParser(java.lang.String rootDir,
java.lang.String regExp,
java.util.Formatter errlog) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getDateFormatMark() |
java.util.regex.Pattern |
getFilter() |
boolean |
getFilterOnName() |
java.nio.file.PathMatcher |
getPathMatcher() |
java.lang.String |
getRootDir() |
static void |
main(java.lang.String[] arg) |
java.lang.String |
toString() |
boolean |
wantSubdirs() |
public CollectionSpecParser(java.lang.String collectionSpec, java.util.Formatter errlog)
collectionSpec
- the collection Specerrlog
- put error messages here, may be nullpublic CollectionSpecParser(java.lang.String rootDir, java.lang.String regExp, java.util.Formatter errlog)
public java.nio.file.PathMatcher getPathMatcher()
public java.lang.String getRootDir()
public boolean wantSubdirs()
public java.util.regex.Pattern getFilter()
public boolean getFilterOnName()
public java.lang.String getDateFormatMark()
public java.lang.String toString()
toString
in class java.lang.Object
public static void main(java.lang.String[] arg)