6 namespace Deveel.Data.Protocol {
17 if (openConnections == 0) {
27 get {
return Client; }
35 return Database.DatabaseContext.Configuration;
43 public bool IsBooted {
59 throw new ObjectDisposedException(GetType().FullName);
65 if (String.IsNullOrEmpty(adminUser))
66 throw new ArgumentNullException(
"adminUser");
67 if (String.IsNullOrEmpty(adminPassword))
68 throw new ArgumentNullException(
"adminPassword");
76 throw new InvalidOperationException(
"The local database is already booted.");
84 throw new InvalidOperationException(
"The database is not booted.");
89 #region ServerConnector
100 protected override void Dispose(
bool disposing) {
102 Client.openConnections--;
103 if (Client.openConnections <= 0) {
110 base.Dispose(disposing);
bool Exists
Gets a boolean value indicating if the database exists within the context given.
IServerConnector Create(string adminUser, string adminPassword)
bool IsOpen
Gets a boolean value that indicates if the database was open.
override void Dispose(bool disposing)
The default implementation of a database in a system.
The representation of a single database in the system.
void Create(string adminName, string adminPassword)
Creates the database in the context given, granting the administrative control to the user identified...
void Open()
Opens the database making it ready to be accessed.
Defines the contract for the configuration node of a component within the system or of the system its...
IServerConnector Access()
ServerConnector(LocalDatabaseClient client, IDatabaseHandler handler)
LocalDatabaseClient(LocalClient client, IDatabase database)