ucar.ncx
Class NcxCrawler
java.lang.Object
|
+--ucar.ncx.NcxCrawler
- public class NcxCrawler
- extends java.lang.Object
Java standalone application to crawl recursively a local directory tree and extract the metadata
from all netcdf files. Metadata files may be stored in a parallel directory tree
rooted at the specified location, or all in the same directory.
NcxCrawler calls repeteadly the processing method of Ncx to do the actual processing.
Note: because of security restrictions, application will work on local netcdf files only
Note: existing metadata files will be overwritten
|
Constructor Summary |
NcxCrawler(java.lang.String indir,
java.lang.String inext,
java.lang.String outdir,
java.lang.String outext,
boolean outtree)
Constructor assign instance fields, and performs basic checking |
|
Method Summary |
static void |
main(java.lang.String[] args)
Method for standalone run. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NcxCrawler
public NcxCrawler(java.lang.String indir,
java.lang.String inext,
java.lang.String outdir,
java.lang.String outext,
boolean outtree)
throws java.io.FileNotFoundException,
java.io.IOException
- Constructor assign instance fields, and performs basic checking
- Parameters:
indir - root of input directory tree (must be non null)inext - extensions of netcdf files to process (if null, all files are processed)outdir - root of output directory tree (if null, output tree will be same as input)outext - metadata files will be named same as netcdf files + outext
(if null, default extension .ncx is appended to the filename)outtree - true to create a parallel directory tree rooted at outdir,
false to store all files in the same directory outdir
main
public static void main(java.lang.String[] args)
- Method for standalone run.
USAGE: java NcxCrawler -indir:.... [-inext:...] [-outdir:....] [-outext:....] [-outtree:true|false]
- indir: root of input directory tree (mandatory)
- inext: extensions of netcdf files to process (default: process all files)
- outdir: root of output directory tree (default: same as indir)
- outext: metadata files will be named same as netcdf files + outext
- outtree: true to create a parallel directory tree rooted at outdir (default), false
to store all files in the same directory outdir