Package com.mckoi.database.jdbc
Interface LocalBootable
- All Known Implementing Classes:
DefaultLocalBootable
public interface LocalBootable
An interface that is implemented by an object that boots up the database.
This is provided as an interface so that we aren't dependant on the
entire database when compiling the JDBC code.
- Author:
- Tobias Downer
-
Method Summary
Modifier and TypeMethodDescriptionBoots the database with the given configuration.boolean
checkExists
(DBConfig config) Attempts to test if the database exists or not.Connects this interface to the database currently running in this JVM.Attempts to create a new database system with the given name, and the given username/password as the admin user for the system.boolean
isBooted()
Returns true if there is a database currently booted in the current JVM.
-
Method Details
-
create
Attempts to create a new database system with the given name, and the given username/password as the admin user for the system. Once created, the newly created database will be booted up.- Parameters:
config
- the configuration variables.- Throws:
SQLException
-
boot
Boots the database with the given configuration.- Parameters:
config
- the configuration variables.- Throws:
SQLException
-
checkExists
Attempts to test if the database exists or not. Returns true if the database exists.- Parameters:
config
- the configuration variables.- Throws:
SQLException
-
isBooted
Returns true if there is a database currently booted in the current JVM. Otherwise returns false.- Throws:
SQLException
-
connectToJVM
Connects this interface to the database currently running in this JVM.- Throws:
SQLException
-