|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.devexperts.qd.tools.AbstractTool
public abstract class AbstractTool
Base class for all QDS tools.
Field Summary | |
---|---|
protected com.devexperts.qd.tools.Options |
options
|
protected boolean |
useScheme
|
Constructor Summary | |
---|---|
protected |
AbstractTool(boolean useScheme,
boolean waitForeverAtEnd)
Constructor |
Method Summary | |
---|---|
void |
execute(java.lang.String[] args)
Executes this tool. |
protected abstract void |
executeImpl(java.lang.String[] args)
Executes this concrete tool. |
protected java.lang.String |
generateHelpSummary(int screenWidth)
Generates basic help on this tool. |
protected abstract com.devexperts.qd.tools.Option[] |
getOptions()
Returns array with all options used by this tool. |
boolean |
mustWaitForeverAtEnd()
|
protected static void |
noArguments()
|
protected static void |
wrongNumberOfArguments()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final boolean useScheme
protected com.devexperts.qd.tools.Options options
Constructor Detail |
---|
protected AbstractTool(boolean useScheme, boolean waitForeverAtEnd)
useScheme
- indicates whether this tool must use scheme.waitForeverAtEnd
- indicates whether this tool must sleep
forever after initialization.Method Detail |
---|
public void execute(java.lang.String[] args) throws BadToolParametersException, ToolInitializationException
args
- arguments and options.
BadToolParametersException
- if couldn't parse tool arguments or options.
ToolInitializationException
- if couldn't initialize the tool.protected static void wrongNumberOfArguments()
protected static void noArguments()
protected abstract void executeImpl(java.lang.String[] args) throws BadToolParametersException, ToolInitializationException
args
- arguments
BadToolParametersException
- if arguments are invalid.
ToolInitializationException
- if some error occured.protected abstract com.devexperts.qd.tools.Option[] getOptions()
protected java.lang.String generateHelpSummary(int screenWidth)
screenWidth
- width of generated info (in characters).
public boolean mustWaitForeverAtEnd()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |