Public Member Functions | |
LSDDbAdmin (String driver, String server, String user, String passwd) | |
LSDDbAdmin (String driver, String server, String user, String passwd, boolean write) | |
LSDDbAdmin (Connection conn, boolean isread) | |
void | close () |
void | commit () |
Static Public Member Functions | |
static void | initialize (String driver) |
Public Attributes | |
boolean | isConnected = false |
boolean | isReadOnly = false |
boolean | isMultipleDBAccess = false |
LSDDbSession | session = null |
Static Public Attributes | |
static boolean | classLoaded = false |
Private Attributes | |
String | driver = null |
String | server = null |
String | user = null |
String | passwd = null |
openlsd.database.session.LSDDbAdmin.LSDDbAdmin | ( | String | driver, | |
String | server, | |||
String | user, | |||
String | passwd | |||
) |
This version creates a default write enabled connection.
A this time, only one driver is possible! If a new driver is needed, then we need to create a new LSDDbSession object. Be aware that LSDDbSession.initialize should be call only once for each driver, whatever the number of LSDDbSession objects that could be created (=> need a hashtable for specific driver when created). Also, don't know if two drivers at the same time (two different LSDDbSession) is allowed by JDBC.
driver | ||
server | ||
user | ||
passwd |
openlsd.database.session.LSDDbAdmin.LSDDbAdmin | ( | String | driver, | |
String | server, | |||
String | user, | |||
String | passwd, | |||
boolean | write | |||
) |
This version creates can create a read only connection if write is false.
A this time, only one driver is possible! If a new driver is needed, then we need to create a new LSDDbSession object. Be aware that LSDDbSession.initialize should be call only once for each driver, whatever the number of LSDDbSession objects that could be created (=> need a hashtable for specific driver when created). Also, don't know if two drivers at the same time (two different LSDDbSession) is allowed by JDBC.
driver | ||
server | ||
user | ||
passwd | ||
write |
openlsd.database.session.LSDDbAdmin.LSDDbAdmin | ( | Connection | conn, | |
boolean | isread | |||
) |
Use a given connexion to create the context.
A this time, only one driver is possible! If a new driver is needed, then we need to create a new LSDDbSession object. Be aware that LSDDbSession.initialize should be call only once for each driver, whatever the number of LSDDbSession objects that could be created (=> need a hashtable for specific driver when created). Also, don't know if two drivers at the same time (two different LSDDbSession) is allowed by JDBC.
This version use given connection. typeDriver must be set before !
conn | ||
isread |
static void openlsd.database.session.LSDDbAdmin.initialize | ( | String | driver | ) | [static] |
Load the correct jdbc driver (default com.mysql.jdbc.Driver)
driver |
void openlsd.database.session.LSDDbAdmin.close | ( | ) |
Close the underlying session. Can be call even for connection given from the constructor LSDDbAdmin(Connection, boolean).
void openlsd.database.session.LSDDbAdmin.commit | ( | ) |
Commit on connection
String openlsd.database.session.LSDDbAdmin.driver = null [private] |
DB Driver
String openlsd.database.session.LSDDbAdmin.server = null [private] |
DB Server
String openlsd.database.session.LSDDbAdmin.user = null [private] |
DB User
String openlsd.database.session.LSDDbAdmin.passwd = null [private] |
DB Password
boolean openlsd.database.session.LSDDbAdmin.isConnected = false |
Is this DB Admin connected
boolean openlsd.database.session.LSDDbAdmin.isReadOnly = false |
Is this DB Admin Read Only
boolean openlsd.database.session.LSDDbAdmin.isMultipleDBAccess = false |
Is this DB Admin accessed by only one thread at a time (no concurrency and no lock/unlock problem)
session is the Session object for all type of requests
boolean openlsd.database.session.LSDDbAdmin.classLoaded = false [static] |
Info on JDBC Class is already loaded or not