org.archiviststoolkit.maintenance.upgrades
Class UpgradeTo_1_7_0

java.lang.Object
  extended by org.archiviststoolkit.maintenance.upgrades.Upgrade
      extended by org.archiviststoolkit.maintenance.upgrades.UpgradeTo_1_7_0

public class UpgradeTo_1_7_0
extends Upgrade


Field Summary
 
Fields inherited from class org.archiviststoolkit.maintenance.upgrades.Upgrade
errorString
 
Constructor Summary
UpgradeTo_1_7_0()
           
 
Method Summary
protected  boolean doUpgrade(java.sql.Connection conn, int initialStep, int numberOfSteps, org.netbeans.spi.wizard.DeferredWizardResult.ResultProgressHandle progress)
           
protected  int getNumberOfSteps()
           
protected  java.lang.String getWarningMessage()
           
protected  boolean runFieldInit()
           
protected  boolean runLoadLookupLists()
           
protected  boolean runPostDBInitializationSQLCode(java.sql.Connection conn)
          Run any sql and hibernate code that needs to be ran after the database has been initialized by hibernate.
protected  void setRepository(DigitalObjects digitalObject, Repositories repository)
          Method to set the digital object repositories
protected  boolean upgradeNeeded(java.sql.Connection conn)
           
 
Methods inherited from class org.archiviststoolkit.maintenance.upgrades.Upgrade
fixListValues, getErrorString, runDetermineSequenceNumbers, runPostDBInitializationCode, setErrorString, updateFieldValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UpgradeTo_1_7_0

public UpgradeTo_1_7_0()
Method Detail

doUpgrade

protected boolean doUpgrade(java.sql.Connection conn,
                            int initialStep,
                            int numberOfSteps,
                            org.netbeans.spi.wizard.DeferredWizardResult.ResultProgressHandle progress)
Specified by:
doUpgrade in class Upgrade

runPostDBInitializationSQLCode

protected boolean runPostDBInitializationSQLCode(java.sql.Connection conn)
Run any sql and hibernate code that needs to be ran after the database has been initialized by hibernate.

Overrides:
runPostDBInitializationSQLCode in class Upgrade
Parameters:
conn - The connection to the database
Returns:
true if all the code executed fine

setRepository

protected void setRepository(DigitalObjects digitalObject,
                             Repositories repository)
Method to set the digital object repositories

Parameters:
digitalObject - The digital object
repository - The repository

getNumberOfSteps

protected int getNumberOfSteps()
Specified by:
getNumberOfSteps in class Upgrade

runLoadLookupLists

protected boolean runLoadLookupLists()
Overrides:
runLoadLookupLists in class Upgrade

runFieldInit

protected boolean runFieldInit()
Overrides:
runFieldInit in class Upgrade

upgradeNeeded

protected boolean upgradeNeeded(java.sql.Connection conn)
                         throws java.sql.SQLException
Specified by:
upgradeNeeded in class Upgrade
Throws:
java.sql.SQLException

getWarningMessage

protected java.lang.String getWarningMessage()
Overrides:
getWarningMessage in class Upgrade