|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdk.netarkivet.common.utils.SettingsFactory<DBSpecifics>
dk.netarkivet.harvester.datamodel.DBSpecifics
public abstract class DBSpecifics
Abstract collection of DB methods that are not standard SQL. This class is a singleton class whose actual implementation is provided by a subclass as determined by the DB_SPECIFICS_CLASS setting.
Constructor Summary | |
---|---|
DBSpecifics()
|
Method Summary | |
---|---|
abstract void |
backupDatabase(java.io.File backupDir)
Backup the database. |
abstract void |
dropJobConfigsTmpTable(java.sql.Connection c,
java.lang.String tableName)
Dispose of a temporary table gotten with getTemporaryTable. |
abstract java.lang.String |
getDriverClassName()
Get the name of the JDBC driver class that handles interfacing to this server. |
static DBSpecifics |
getInstance()
Get the singleton instance of the DBSpecifics implementation class |
abstract java.lang.String |
getJobConfigsTmpTable(java.sql.Connection c)
Get a temporary table for short-time use. |
abstract void |
shutdownDatabase()
Shutdown the database system, if running embeddedly. |
void |
updateTable(java.lang.String tableName,
int toVersion)
Update a table to a newer version, if necessary. |
Methods inherited from class dk.netarkivet.common.utils.SettingsFactory |
---|
getInstance |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DBSpecifics()
Method Detail |
---|
public static DBSpecifics getInstance()
public abstract void shutdownDatabase()
public abstract java.lang.String getJobConfigsTmpTable(java.sql.Connection c) throws java.sql.SQLException
c
- The DB connection to use.
java.sql.SQLException
- if there is a problem getting the table.public abstract void dropJobConfigsTmpTable(java.sql.Connection c, java.lang.String tableName)
c
- The DB connection to use.tableName
- The name of the temporarily created table.public abstract void backupDatabase(java.io.File backupDir) throws java.sql.SQLException
backupDir
- Directory to which the database should be backed up
java.sql.SQLException
PermissionDenied
- if the directory cannot be created.public abstract java.lang.String getDriverClassName()
public void updateTable(java.lang.String tableName, int toVersion)
tableName
- The table to updatetoVersion
- The version to update the table to.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |