Package com.cosylab.vdct.rdb
Class RdbConnection
- java.lang.Object
-
- com.cosylab.vdct.rdb.RdbConnection
-
public class RdbConnection extends Object
- Author:
- ssah
-
-
Constructor Summary
Constructors Constructor Description RdbConnection()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
appendRow(String table, Object[][] keyPairs, Object[][] valuePairs)
void
closeConnection()
void
commit()
Connection
createConnection()
void
deleteRows(String table, Object[][] keyPairs)
void
displayStatistics()
Connection
getConnection()
void
insertRow(String table, Object[][] keyPairs, Object[][] valuePairs)
boolean
isConnection()
ResultSet
loadRows(String table, Object[] columns, Object[][] keyPairs)
ResultSet
loadRows(String table, Object[] columns, Object[][] keyPairs, String conditions)
ResultSet
loadRows(String table, Object[] columns, Object[][] keyPairs, String conditions, String orderBy)
void
resetStatistics()
void
rollbackConnection()
void
saveRow(String table, Object[][] keyPairs, Object[][] valuePairs)
void
setParameters(String host, String database, String user, String password)
void
updateRow(String table, Object[][] keyPairs, Object[][] valuePairs)
-
-
-
Method Detail
-
setParameters
public void setParameters(String host, String database, String user, String password)
- Parameters:
host
- hostdatabase
- databaseuser
- userpassword
- password
-
isConnection
public boolean isConnection()
- Returns:
- something
-
commit
public void commit() throws SQLException
- Throws:
SQLException
- foo
-
createConnection
public Connection createConnection() throws SQLException
- Returns:
- something
- Throws:
SQLException
- foo
-
getConnection
public Connection getConnection()
- Returns:
- something
-
rollbackConnection
public void rollbackConnection() throws SQLException
- Throws:
SQLException
- foo
-
closeConnection
public void closeConnection() throws SQLException
- Throws:
SQLException
- foo
-
loadRows
public ResultSet loadRows(String table, Object[] columns, Object[][] keyPairs) throws SQLException
- Parameters:
table
- tablecolumns
- columnskeyPairs
- keyPairs- Returns:
- something
- Throws:
SQLException
- foo
-
loadRows
public ResultSet loadRows(String table, Object[] columns, Object[][] keyPairs, String conditions) throws SQLException
- Parameters:
table
- tablecolumns
- columnskeyPairs
- keyPairsconditions
- conditions- Returns:
- something
- Throws:
SQLException
- foo
-
loadRows
public ResultSet loadRows(String table, Object[] columns, Object[][] keyPairs, String conditions, String orderBy) throws SQLException
- Parameters:
table
- tablecolumns
- columnskeyPairs
- keyPairsconditions
- conditionsorderBy
- orderBy- Returns:
- something
- Throws:
SQLException
- foo
-
insertRow
public void insertRow(String table, Object[][] keyPairs, Object[][] valuePairs) throws SQLException
- Parameters:
table
- tablekeyPairs
- keyPairsvaluePairs
- valuePairs- Throws:
SQLException
- foo
-
updateRow
public void updateRow(String table, Object[][] keyPairs, Object[][] valuePairs) throws SQLException
- Parameters:
table
- tablekeyPairs
- keyPairsvaluePairs
- valuePairs- Throws:
SQLException
- foo
-
deleteRows
public void deleteRows(String table, Object[][] keyPairs) throws SQLException
- Parameters:
table
- tablekeyPairs
- keyPairs- Throws:
SQLException
- foo
-
saveRow
public void saveRow(String table, Object[][] keyPairs, Object[][] valuePairs) throws SQLException
- Parameters:
table
- tablekeyPairs
- keyPairsvaluePairs
- valuePairs- Throws:
SQLException
- foo
-
appendRow
public void appendRow(String table, Object[][] keyPairs, Object[][] valuePairs) throws SQLException
- Parameters:
table
- tablekeyPairs
- keyPairsvaluePairs
- valuePairs- Throws:
SQLException
- foo
-
displayStatistics
public void displayStatistics()
-
resetStatistics
public void resetStatistics()
-
-