henplus.commands
Class AboutCommand
java.lang.Object
henplus.AbstractCommand
henplus.commands.AboutCommand
- All Implemented Interfaces:
- Command
public class AboutCommand
- extends AbstractCommand
document me.
Methods inherited from class henplus.AbstractCommand |
argumentCount, complete, getLongDescription, getOption, getOptions, getSynopsis, handleCommandline, isComplete, participateInCommandCompletion, registerOptions, setOptions, shutdown |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AboutCommand
public AboutCommand(boolean quiet)
getCommandList
public String[] getCommandList()
- returns the command-strings this command can handle.
execute
public int execute(SQLSession session,
String cmd,
String param)
- execute the command given.
- Parameters:
session
- the SQLsession this command is executed from.cmd
- the command as string.param
- the rest parameters following the command.
- Returns:
- one of SUCCESS, SYNTAX_ERROR, EXEC_FAILED to indicate
the exit status of this command. On SYNTAX_ERROR, the
CommandDispatcher displays a synopsis if available.
requiresValidSession
public boolean requiresValidSession(String cmd)
- Description copied from interface:
Command
- returns true, if this command requires a valid SQLSession, i.e. if the
Command.execute(SQLSession,String,String)
method makes use of the
session (e.g. to get some Database connection) or not. Return 'true'
if unsure (you should be sure..). This is to thwart attempts to
execute a command without session.
- Specified by:
requiresValidSession
in interface Command
- Overrides:
requiresValidSession
in class AbstractCommand
- Parameters:
cmd
- the subcommand this is requested for; one of the
commands returned by Command.getCommandList()
.
getShortDescription
public String getShortDescription()
- return a descriptive string.
- Specified by:
getShortDescription
in interface Command
- Overrides:
getShortDescription
in class AbstractCommand
? 1997..2006 Henner Zeller