public class SMYLDDataBaseHandler extends SMYLDObject implements DBConstants
| Modifier and Type | Field and Description |
|---|---|
static int |
DB_SEQUENTIAL_NO_WIDTH |
static String |
DB_VAL_NoParentFieldValue
Holds value (in data base) of the parent id in case there is not parent
|
protected Connection |
dbConnection
Holds the connection to the data base
|
protected SMYLDDBUtility |
dbUtility
serves for the different data base access methods
|
protected DBConnection |
smyldDBConnection |
NEW_LINE, OS_NEW_LINEDB_ERR_CONNECTION_RESET, DB_ERR_CONNECTION_RESET_TEXT, DB_ERR_UNIQUE_CONSTRAINT, DB_ERR_UNKNOWN, DB_VENDOR_DB2, DB_VENDOR_DEFAULT, DB_VENDOR_MYSQL, DB_VENDOR_ORACLE, DB_VENDOR_SQL_SERVER, DB_VENDOR_SYBASE| Constructor and Description |
|---|
SMYLDDataBaseHandler(DBErrorHandler e)
In this constructor, the class will open connection to the data base, and
will load the required tables according to method calls
|
SMYLDDataBaseHandler(DBErrorHandler e,
DBConnection connection) |
SMYLDDataBaseHandler(DBErrorHandler e,
String userName,
String userPassword,
String host,
String port,
String dbname) |
SMYLDDataBaseHandler(int driver,
DBErrorHandler e,
String userName,
String userPassword,
String host,
String port,
String dbname) |
debug, getLenName, insertInstanceValue, printInstanceValues, toStringprotected Connection dbConnection
protected DBConnection smyldDBConnection
protected SMYLDDBUtility dbUtility
public static final String DB_VAL_NoParentFieldValue
public static final int DB_SEQUENTIAL_NO_WIDTH
public SMYLDDataBaseHandler(DBErrorHandler e)
public SMYLDDataBaseHandler(DBErrorHandler e, DBConnection connection)
public SMYLDDataBaseHandler(DBErrorHandler e, String userName, String userPassword, String host, String port, String dbname)
public void setSMYLDConnection(DBConnection newActiveConnection)
public Utility getUtility()
public boolean isConnected()
public DBConnection getSMYLDConnection()
public void closeConnection()
throws SQLException
SQLExceptionpublic void doCommit()
public void doRollBack()
public void addDBConnectionListener(DBConnectionListener newConnectionListener)
public void addDBConnectionListener(DBConnectionListener newConnectionListener, int priorty)
public void executeDoubleParamFunction(String function, String param1, String param2)
public void executeDoubleParamFunction(String function, int param1, int param2)
public void executeTrippleParamFunction(String function, String param1, String param2, String param3)
public void executeDoubleParamProcedure(String procedure, int param1, int param2)
public void executeTrippleParamProcedure(String procedure, String param1, int param2, int param3)
public Array executeSingleParamOraArrayFun(String function, String arrayTypeName, int param1)
public void executeMultiParamProcedure(String procedureName, String[] params)
public void setDBConnection(DBConnection newActiveDBConnection)
protected void handleDBError(Exception ex)
public int getTableTotalRecordsNumber(String tableName)
Copyright © 2019 SMYLD. All rights reserved.