Package org.htmlcleaner
Class CommandLine
- java.lang.Object
-
- org.htmlcleaner.CommandLine
-
public class CommandLine extends java.lang.ObjectCommand line usage class.
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.StringclassNameprivate static java.util.logging.Loggerloggerprivate static java.lang.StringOMITXMLDECL
-
Constructor Summary
Constructors Constructor Description CommandLine()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static java.lang.StringgetArgValue(java.lang.String[] args, java.lang.String name, java.lang.String defaultValue)private static booleangetSwitchArgument(java.lang.String[] args, java.lang.String name)If the specified argument name exists without a value, return true.static voidmain(java.lang.String[] args)private static booleantoBoolean(java.lang.String s)
-
-
-
Field Detail
-
OMITXMLDECL
private static final java.lang.String OMITXMLDECL
- See Also:
- Constant Field Values
-
className
private static final java.lang.String className
-
logger
private static final java.util.logging.Logger logger
-
-
Method Detail
-
getSwitchArgument
private static boolean getSwitchArgument(java.lang.String[] args, java.lang.String name)If the specified argument name exists without a value, return true. If it exists with a value, translate it as a boolean.- Parameters:
args- the command line argumentsname- the switch name- Returns:
- true, or false, depending on whether the switch has been specified
-
getArgValue
private static java.lang.String getArgValue(java.lang.String[] args, java.lang.String name, java.lang.String defaultValue)
-
toBoolean
private static boolean toBoolean(java.lang.String s)
-
main
public static void main(java.lang.String[] args) throws java.io.IOException, XPatherException- Throws:
java.io.IOExceptionXPatherException
-
-