public class JDBCDatabaseInterface extends AbstractJDBCDatabaseInterface
This receives database commands and dispatches them to the database system. This assumes that all calls to the methods here are in a UserWorkerThread thread.
NOTE: Currently, the client/server use of this object isn't multi-threaded, however the local connection could be. Therefore, this object has been made multi-thread safe.
Constructor and Description |
---|
JDBCDatabaseInterface(Database database,
String host_name)
Sets up the processor.
|
Modifier and Type | Method and Description |
---|---|
void |
dispose()
Called when the connection is disposed.
|
QueryResponse |
execQuery(SQLQuery query)
Executes the query and returns a QueryResponse object that describes the
result of the query.
|
boolean |
login(String default_schema,
String username,
String password,
DatabaseCallBack database_call_back)
Attempts to log in to the database as the given username with the given
password.
|
checkNotDisposed, clearResultSetMap, Debug, disposeResult, disposeStreamableObject, finalize, getDatabase, getDatabaseConnection, getResultPart, getStreamableObjectPart, getUser, handleExecuteThrowable, init, internalDispose, pushStreamableObjectPart
public boolean login(String default_schema, String username, String password, DatabaseCallBack database_call_back) throws SQLException
DatabaseInterface
A DatabaseCallBack implementation must be given here that is notified of all events from the database. Events are only received if the login was successful.
SQLException
public QueryResponse execQuery(SQLQuery query) throws SQLException
DatabaseInterface
execQuery
in interface DatabaseInterface
execQuery
in class AbstractJDBCDatabaseInterface
SQLException
public void dispose() throws SQLException
DatabaseInterface
SQLException
Copyright © 2015. All rights reserved.