|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectca.umontreal.iro.rali.Options
public class Options
Parsing of command line options and keep their values that can be shared by the Explore and Extract classes.
Field Summary | |
---|---|
static boolean |
debug
Global option (-d): will show debugging information during execution |
protected static java.lang.String |
inputFileName
Last parameter: Name of the input file, if it is null then standard input is used |
protected static int |
maxRes
Extract option (-max): stop reading the file after a given number of results (infinite if not specified) |
protected static NamespaceContext |
nsContext
keep track of the namespaces used in the input document |
protected static boolean |
onlyCount
Extract option (-c): return only the number of extracted nodes |
protected static boolean |
outAttr
Explore option (-a): output attribute names in XPath expression |
protected static boolean |
outAttrVal
Explore option (-av): output attribute names and values in XPath expression |
protected static java.lang.String |
outputFileName
Global option (-o): Name of the output file, if it is null then standard output is used |
protected static boolean |
outVal
Explore option (-v): output element values in XPath expression |
protected static boolean |
prettyPrint
Extract option (-pp): output a prettyprinted version of the extracted node |
protected static java.lang.String |
rootName
Extract option (-r): name of the root element ( root if not given) |
protected static boolean |
sax
|
protected static boolean |
showNamespaces
Explore option (-ns): show the values of the namespaces used in XPath expressions |
protected static boolean |
sortAlpha
Explore option (-sa): sort the XPath expressions alphabetically |
protected static boolean |
sortFreq
Explore option (-sf): sort the XPath expression by decreasing frequency |
protected static boolean |
statistics
Global option (-st): will show statistics information at the end of execution |
protected static java.lang.String |
XML_NS
|
protected static java.lang.String |
xpathStr
Extract option (-xp): XPath expression used to select nodes to extract |
protected static java.util.Map<java.lang.String,java.lang.String> |
xslParams
List of parameters for the xsl stylesheets (they are set to both individual and final stylesheets) |
protected static java.lang.String |
xsltFile
Extract option (-xsl): XSLT stylesheet to apply to each extracted node |
protected static java.lang.String |
xsltFileFinal
Extract option (-xslf): XSLT stylesheet to apply to the resulting document |
Constructor Summary | |
---|---|
Options()
|
Method Summary | |
---|---|
protected static void |
parseArgs(java.lang.String[] args)
Parse program arguments and set appropriate options will stop on -h : prints usage of the program -xpt: prints the xpath expression as it is seen by the program will stop on an unrecognized arguments |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final java.lang.String XML_NS
public static boolean debug
protected static boolean statistics
protected static java.lang.String inputFileName
protected static java.lang.String outputFileName
protected static boolean sax
protected static boolean outAttr
protected static boolean outAttrVal
protected static boolean outVal
protected static boolean sortAlpha
protected static boolean sortFreq
protected static boolean showNamespaces
protected static java.lang.String xpathStr
protected static java.lang.String xsltFile
protected static java.lang.String xsltFileFinal
protected static java.util.Map<java.lang.String,java.lang.String> xslParams
protected static java.lang.String rootName
root
if not given)
protected static boolean onlyCount
protected static boolean prettyPrint
protected static int maxRes
protected static NamespaceContext nsContext
Constructor Detail |
---|
public Options()
Method Detail |
---|
protected static void parseArgs(java.lang.String[] args)
args
- String array as given to the main program
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |