Interface IDatabaseControllerExtensionPluginInterface
-
public interface IDatabaseControllerExtensionPluginInterface
This plugin-interface is being called multiple times inside theDatabaseController
in any method of the same name.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
checkIfIsSelect(String sql, Map<Object,Object> mapOfData)
Checks if the current sql-statement is a SELECT statement or not.
For example: in the Hibernate-plugin a "FROM" keyword can also start a select-statement.void
closeConnection(ExecutorService es, int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.closeConnection(ExecutorService, int, Map)
KeyValue<String,SQLTable>
createTempSQLTable(int connectionPoolId, SQLTextEditor<?> editor, SQLDatabase database, String sql, Map<Object,Object> mapOfData, boolean fillContent)
void
doCommit(int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.doCommit(int, Map)
void
doRollback(int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.doRollback(int, Map)
Exception
executeSQL(int connectionPoolId, SQLDatabase database, String sql, SQLTextEditor<?> editor, IDoingAfterThread d)
Method to overwriteDatabaseController.executeSQL(int, SQLDatabase, String, SQLTextEditor, IDoingAfterThread)
.
Has to return the Exception if one occured otherwise null.String
getMode()
Returns the "MODE"-indenticator for theSQLTextEditor
.
Default-Mode is "SQL" and is set when creating aSQLTextEditor
.
If this method returns another value, the default behaviour for executing SQL doesn't work anymore and has to be replaced.boolean
hasConnection(int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.hasConnection(int, Map)
void
reconnect(ExecutorService es, int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.reconnect(ExecutorService, int, Map)
void
reconnect(ExecutorService es, int connectionPoolId, SQLDatabase database, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.reconnect(ExecutorService, int, SQLDatabase, Map)
-
-
-
Method Detail
-
hasConnection
boolean hasConnection(int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.hasConnection(int, Map)
- Parameters:
connectionPoolId
-mapOfData
-- Returns:
-
doRollback
void doRollback(int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.doRollback(int, Map)
- Parameters:
connectionPoolId
-mapOfData
-
-
doCommit
void doCommit(int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.doCommit(int, Map)
- Parameters:
connectionPoolId
-mapOfData
-
-
reconnect
void reconnect(ExecutorService es, int connectionPoolId, Map<Object,Object> mapOfData) throws Exception
Method to overwriteDatabaseController.reconnect(ExecutorService, int, Map)
- Parameters:
es
-connectionPoolId
-mapOfData
-- Throws:
Exception
-
reconnect
void reconnect(ExecutorService es, int connectionPoolId, SQLDatabase database, Map<Object,Object> mapOfData) throws Exception
Method to overwriteDatabaseController.reconnect(ExecutorService, int, SQLDatabase, Map)
- Parameters:
es
-connectionPoolId
-database
-mapOfData
-- Throws:
Exception
-
closeConnection
void closeConnection(ExecutorService es, int connectionPoolId, Map<Object,Object> mapOfData)
Method to overwriteDatabaseController.closeConnection(ExecutorService, int, Map)
- Parameters:
es
-connectionPoolId
-mapOfData
-
-
checkIfIsSelect
boolean checkIfIsSelect(String sql, Map<Object,Object> mapOfData)
Checks if the current sql-statement is a SELECT statement or not.
For example: in the Hibernate-plugin a "FROM" keyword can also start a select-statement.- Parameters:
sql
-mapOfData
-- Returns:
-
createTempSQLTable
KeyValue<String,SQLTable> createTempSQLTable(int connectionPoolId, SQLTextEditor<?> editor, SQLDatabase database, String sql, Map<Object,Object> mapOfData, boolean fillContent)
Method to overwriteDatabaseController.createTempSQLTable(int, SQLTextEditor, SQLDatabase, String, Map, boolean)
- Parameters:
connectionPoolId
-editor
-database
-sql
-mapOfData
-fillContent
-- Returns:
-
executeSQL
Exception executeSQL(int connectionPoolId, SQLDatabase database, String sql, SQLTextEditor<?> editor, IDoingAfterThread d)
Method to overwriteDatabaseController.executeSQL(int, SQLDatabase, String, SQLTextEditor, IDoingAfterThread)
.
Has to return the Exception if one occured otherwise null.- Parameters:
connectionPoolId
-database
-sql
-editor
-d
-- Returns:
-
getMode
String getMode()
Returns the "MODE"-indenticator for theSQLTextEditor
.
Default-Mode is "SQL" and is set when creating aSQLTextEditor
.
If this method returns another value, the default behaviour for executing SQL doesn't work anymore and has to be replaced.- Returns:
-
-