Package adams.tools
Class TableUpgrade
-
- All Implemented Interfaces:
CleanUpHandler,Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,SizeOfHandler,Stoppable,StoppableWithFeedback,DatabaseConnectionHandler,DatabaseConnectionProvider,DatabaseConnectionUser,Serializable,Comparable
public class TableUpgrade extends AbstractDatabaseTool
Tool for running a specific table upgrade.
Valid options are:
-D (property: debug) If set to true, scheme may output additional info to the console.-upgrade <adams.db.upgrade.AbstractTableUpgrade [options]> (property: tableUpgrade) The table upgrade scheme to use. default: adams.db.upgrade.PassThroughDefault options for adams.db.upgrade.PassThrough (-upgrade/tableUpgrade):-D (property: debug) If set to true, scheme may output additional info to the console.- Version:
- $Revision$
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected AbstractTableUpgradem_TableUpgradethe table upgrade to run.-
Fields inherited from class adams.tools.AbstractDatabaseTool
m_dbc
-
Fields inherited from class adams.tools.AbstractTool
m_Stopped
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description TableUpgrade()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddefineOptions()Adds options to the internal list of options.protected voiddoRun()Attempt to run the table upgrade scheme.protected AbstractDatabaseConnectiongetDefaultDatabaseConnection()Returns the default database connection.AbstractTableUpgradegetTableUpgrade()Returns the table upgrade to use.StringglobalInfo()Returns a string describing the object.voidsetTableUpgrade(AbstractTableUpgrade value)Sets the table upgrade to use.StringtableUpgradeTipText()Returns the tip text for this property.-
Methods inherited from class adams.tools.AbstractDatabaseTool
cleanUp, getDatabaseConnection, initialize, setDatabaseConnection
-
Methods inherited from class adams.tools.AbstractTool
compareTo, destroy, equals, forCommandLine, forName, getTools, isStopped, postRun, preRun, run, runTool, stopExecution
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, finishInit, getDefaultLoggingLevel, getOptionManager, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_TableUpgrade
protected AbstractTableUpgrade m_TableUpgrade
the table upgrade to run.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfoin interfaceGlobalInfoSupporter- Specified by:
globalInfoin classAbstractOptionHandler- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractOptionHandler
-
getDefaultDatabaseConnection
protected AbstractDatabaseConnection getDefaultDatabaseConnection()
Returns the default database connection.- Specified by:
getDefaultDatabaseConnectionin classAbstractDatabaseTool- Returns:
- the database connection
-
setTableUpgrade
public void setTableUpgrade(AbstractTableUpgrade value)
Sets the table upgrade to use.- Parameters:
value- the table upgrade to use
-
getTableUpgrade
public AbstractTableUpgrade getTableUpgrade()
Returns the table upgrade to use.- Returns:
- the table upgrade to use
-
tableUpgradeTipText
public String tableUpgradeTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
doRun
protected void doRun()
Attempt to run the table upgrade scheme.- Specified by:
doRunin classAbstractTool
-
-