Class HSqlDbAdminHandler
- java.lang.Object
-
- com.openindex.openestate.tool.db.DbAdminHandlerImpl
-
- com.openindex.openestate.tool.db.hsql.HSqlDbAdminHandler
-
- All Implemented Interfaces:
DbAdminHandler
public class HSqlDbAdminHandler extends DbAdminHandlerImpl
HSqlDbAdminHandler.- Author:
- Andreas Rudolph
-
-
Constructor Summary
Constructors Constructor Description HSqlDbAdminHandler()
-
Method Summary
-
Methods inherited from class com.openindex.openestate.tool.db.DbAdminHandlerImpl
hasRole, isAdmin, isEnabled
-
-
-
-
Method Detail
-
backupLocalDb
public final void backupLocalDb(Connection c, File backupArchive) throws SQLException
- Specified by:
backupLocalDb
in interfaceDbAdminHandler
- Specified by:
backupLocalDb
in classDbAdminHandlerImpl
- Throws:
SQLException
-
backupRemoteDb
public final void backupRemoteDb(Connection c, String dbName) throws SQLException
- Specified by:
backupRemoteDb
in interfaceDbAdminHandler
- Specified by:
backupRemoteDb
in classDbAdminHandlerImpl
- Throws:
SQLException
-
createAccount
public final void createAccount(Connection c, String account, char[] password) throws SQLException
- Specified by:
createAccount
in interfaceDbAdminHandler
- Specified by:
createAccount
in classDbAdminHandlerImpl
- Throws:
SQLException
-
defrag
public final void defrag(Connection c) throws SQLException
- Specified by:
defrag
in interfaceDbAdminHandler
- Specified by:
defrag
in classDbAdminHandlerImpl
- Throws:
SQLException
-
dumpLocalDb
public final void dumpLocalDb(Connection c, File backupArchive) throws SQLException
- Specified by:
dumpLocalDb
in interfaceDbAdminHandler
- Specified by:
dumpLocalDb
in classDbAdminHandlerImpl
- Throws:
SQLException
-
getAccounts
public final String[] getAccounts(Connection c, boolean includeAdmin) throws SQLException
- Specified by:
getAccounts
in interfaceDbAdminHandler
- Specified by:
getAccounts
in classDbAdminHandlerImpl
- Throws:
SQLException
-
getProcedures
public final String[] getProcedures(Connection c) throws SQLException
- Specified by:
getProcedures
in interfaceDbAdminHandler
- Specified by:
getProcedures
in classDbAdminHandlerImpl
- Throws:
SQLException
-
getRoles
public final String[] getRoles(Connection c, boolean includeAdmin) throws SQLException
- Specified by:
getRoles
in interfaceDbAdminHandler
- Specified by:
getRoles
in classDbAdminHandlerImpl
- Throws:
SQLException
-
getSessions
public final DbSession[] getSessions(Connection c) throws SQLException
- Specified by:
getSessions
in interfaceDbAdminHandler
- Specified by:
getSessions
in classDbAdminHandlerImpl
- Throws:
SQLException
-
getTables
public final String[] getTables(Connection c) throws SQLException
- Specified by:
getTables
in interfaceDbAdminHandler
- Specified by:
getTables
in classDbAdminHandlerImpl
- Throws:
SQLException
-
getViews
public final String[] getViews(Connection c) throws SQLException
- Specified by:
getViews
in interfaceDbAdminHandler
- Specified by:
getViews
in classDbAdminHandlerImpl
- Throws:
SQLException
-
grantRole
public boolean grantRole(Connection c, String account, String role) throws SQLException
- Specified by:
grantRole
in interfaceDbAdminHandler
- Specified by:
grantRole
in classDbAdminHandlerImpl
- Throws:
SQLException
-
hasRole
public final boolean hasRole(Connection c, String account, String role) throws SQLException
- Specified by:
hasRole
in interfaceDbAdminHandler
- Specified by:
hasRole
in classDbAdminHandlerImpl
- Throws:
SQLException
-
isAdmin
public final boolean isAdmin(Connection c, String account) throws SQLException
- Specified by:
isAdmin
in interfaceDbAdminHandler
- Specified by:
isAdmin
in classDbAdminHandlerImpl
- Throws:
SQLException
-
isEnabled
public final boolean isEnabled(Connection c, String account) throws SQLException
- Specified by:
isEnabled
in interfaceDbAdminHandler
- Specified by:
isEnabled
in classDbAdminHandlerImpl
- Throws:
SQLException
-
isLocalDbBackupSupported
public final boolean isLocalDbBackupSupported()
- Specified by:
isLocalDbBackupSupported
in interfaceDbAdminHandler
- Specified by:
isLocalDbBackupSupported
in classDbAdminHandlerImpl
-
isLocalDbDumpSupported
public boolean isLocalDbDumpSupported()
- Specified by:
isLocalDbDumpSupported
in interfaceDbAdminHandler
- Specified by:
isLocalDbDumpSupported
in classDbAdminHandlerImpl
-
isRemoteDbBackupSupported
public final boolean isRemoteDbBackupSupported()
- Specified by:
isRemoteDbBackupSupported
in interfaceDbAdminHandler
- Specified by:
isRemoteDbBackupSupported
in classDbAdminHandlerImpl
-
removeAccount
public final void removeAccount(Connection c, String account) throws SQLException
- Specified by:
removeAccount
in interfaceDbAdminHandler
- Specified by:
removeAccount
in classDbAdminHandlerImpl
- Throws:
SQLException
-
revokeRole
public final boolean revokeRole(Connection c, String account, String role) throws SQLException
- Specified by:
revokeRole
in interfaceDbAdminHandler
- Specified by:
revokeRole
in classDbAdminHandlerImpl
- Throws:
SQLException
-
selectLocalBackupFile
public final File selectLocalBackupFile(Component parentComponent, File defaultDir)
- Specified by:
selectLocalBackupFile
in interfaceDbAdminHandler
- Specified by:
selectLocalBackupFile
in classDbAdminHandlerImpl
-
selectLocalDumpFile
public final File selectLocalDumpFile(Component parentComponent, File defaultDir)
- Specified by:
selectLocalDumpFile
in interfaceDbAdminHandler
- Specified by:
selectLocalDumpFile
in classDbAdminHandlerImpl
-
setAdmin
public final void setAdmin(Connection c, String account, boolean isAdmin) throws SQLException
- Specified by:
setAdmin
in interfaceDbAdminHandler
- Specified by:
setAdmin
in classDbAdminHandlerImpl
- Throws:
SQLException
-
setEnabled
public final void setEnabled(Connection c, String account, boolean isEnabled) throws SQLException
- Specified by:
setEnabled
in interfaceDbAdminHandler
- Specified by:
setEnabled
in classDbAdminHandlerImpl
- Throws:
SQLException
-
updateAccount
public final void updateAccount(Connection c, String account, char[] password) throws SQLException
- Specified by:
updateAccount
in interfaceDbAdminHandler
- Specified by:
updateAccount
in classDbAdminHandlerImpl
- Throws:
SQLException
-
-