|
Lvg Java 2006p Version |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgov.nih.nlm.nls.lvg.CmdLineSyntax.SystemOption
public abstract class SystemOption
This is an abstract class for all systems to use and setup system command line syntax. A nice feature of it is to check the syntax of the input command line.
History:
Notes:
It is illegal to have multiple arguments with one of them is NONE
For example: -a:aa~aaa~aab~NONE
Instead, it should change to -a:aa~aaa~aab~none
where none is a pre-defined argument for flag -a
| Field Summary | |
|---|---|
protected Option |
systemOption_
|
| Constructor Summary | |
|---|---|
SystemOption()
Create the system option object |
|
| Method Summary | |
|---|---|
protected static boolean |
CheckOption(OptionItem inItem,
java.lang.String systemItemStr)
|
static boolean |
CheckSyntax(Option option,
Option systemOption,
boolean printRun,
boolean printError)
Check if the input option is legal according to the given system option This method can be used as syntax error checker |
protected abstract void |
DefineFlag()
|
protected abstract void |
ExecuteCommand(OptionItem optionItem,
Option systemOption)
|
void |
ExecuteCommands(Option inOption,
Option systemOption)
Execute a given option in a command line system (with given system option) |
Option |
GetOption()
Get the defined system option of the command line syntax system |
protected boolean |
ToBoolean(java.lang.String in)
|
protected float[] |
ToFloatArray(java.util.Vector inList)
|
protected int[] |
ToIntArray(java.util.Vector inList)
|
protected java.lang.String[] |
ToStringArray(java.util.Vector inList)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Option systemOption_
| Constructor Detail |
|---|
public SystemOption()
| Method Detail |
|---|
public Option GetOption()
public static boolean CheckSyntax(Option option,
Option systemOption,
boolean printRun,
boolean printError)
option - input option to be checkedsystemOption - system option that the checking is based onprintRun - a boolean flag to print algorithm detailsprintError - a boolean flag to print error
public void ExecuteCommands(Option inOption,
Option systemOption)
inOption - option to be executedsystemOption - system option for the command line
protected abstract void ExecuteCommand(OptionItem optionItem,
Option systemOption)
protected abstract void DefineFlag()
protected boolean ToBoolean(java.lang.String in)
protected int[] ToIntArray(java.util.Vector inList)
protected float[] ToFloatArray(java.util.Vector inList)
protected java.lang.String[] ToStringArray(java.util.Vector inList)
protected static boolean CheckOption(OptionItem inItem,
java.lang.String systemItemStr)
|
Lvg Java 2006p Version |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||