henplus.commands.properties
Class PropertyCommand

java.lang.Object
  extended by henplus.AbstractCommand
      extended by henplus.commands.properties.AbstractPropertyCommand
          extended by henplus.commands.properties.PropertyCommand
All Implemented Interfaces:
Command

public class PropertyCommand
extends AbstractPropertyCommand

Set global HenPlus properties.


Field Summary
 
Fields inherited from interface henplus.Command
EXEC_FAILED, SUCCESS, SYNTAX_ERROR
 
Constructor Summary
PropertyCommand(HenPlus henplus, PropertyRegistry registry)
           
 
Method Summary
protected  String getHelpHeader()
           
protected  PropertyRegistry getRegistry()
          the PropertyRegistry associcaed with the current
protected  String getSetCommand()
          returns the name of the command this command reacts on.
 void load()
           
 boolean requiresValidSession(String cmd)
          returns true, if this command requires a valid SQLSession, i.e.
 void shutdown()
          shutdown this command.
 
Methods inherited from class henplus.commands.properties.AbstractPropertyCommand
complete, execute, getCommandList, getLongDescription, getShortDescription, getSynopsis
 
Methods inherited from class henplus.AbstractCommand
argumentCount, getOption, getOptions, handleCommandline, isComplete, participateInCommandCompletion, registerOptions, setOptions
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyCommand

public PropertyCommand(HenPlus henplus,
                       PropertyRegistry registry)
Method Detail

getSetCommand

protected String getSetCommand()
Description copied from class: AbstractPropertyCommand
returns the name of the command this command reacts on.

Specified by:
getSetCommand in class AbstractPropertyCommand

getHelpHeader

protected String getHelpHeader()
Specified by:
getHelpHeader in class AbstractPropertyCommand

getRegistry

protected PropertyRegistry getRegistry()
Description copied from class: AbstractPropertyCommand
the PropertyRegistry associcaed with the current

Specified by:
getRegistry in class AbstractPropertyCommand

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().

load

public void load()

shutdown

public void shutdown()
Description copied from interface: Command
shutdown this command. This is called on exit of the CommandDispatcher and allows you to do some cleanup (close connections, flush files..)

Specified by:
shutdown in interface Command
Overrides:
shutdown in class AbstractCommand


? 1997..2006 Henner Zeller