Interface DBInterface
- All Known Subinterfaces:
- ConfigurationInterface
- All Known Implementing Classes:
- AbstractDBInterface,- PersistenceSession.PersistenceSessionDBInterface
public interface DBInterface
- 
Nested Class SummaryNested ClassesModifier and TypeInterfaceDescriptionstatic interfaceA transaction represents a sequence of commands that need to be executed as a group, or not at all.
- 
Method SummaryModifier and TypeMethodDescriptionlongGets the next value in a named integer sequence.longgetSeq(String seqName, Connection connection) Like the other getSeq, but operates against a particular local db connection, which may be necessary if the sequence generation is part of a transaction.runPrepQuery(String query, Object... args) Runs the given SELECT query as a prepared statement, after setting the arguments in the varargs list.intrunPrepUpdate(String query, Serializable... args) Runs the given UPDATE/INSERT/DELETE query as a prepared statement, after setting the arguments in the varargs list.Runs the given SELECT query, and returns the results in a List of Lists of Objects.runScalarQuery(String query) Runs the given SELECT query, returns the value in the first row of the first column, as its natural type.Creates a connection, and runs the given transaction.intrunUpdateQuery(String query) Runs the given UPDATE/INSERT/DELETE query, and returns the number of rows affected.
- 
Method Details- 
getConnection- Throws:
- SQLException
 
- 
runScalarQueryRuns the given SELECT query, returns the value in the first row of the first column, as its natural type. If no rows are returned, null is returned.- Throws:
- SQLException
 
- 
runQueryRuns the given SELECT query, and returns the results in a List of Lists of Objects.- Throws:
- SQLException
 
- 
runPrepQueryRuns the given SELECT query as a prepared statement, after setting the arguments in the varargs list. Returns the results in a List of Lists of Objects.- Throws:
- SQLException
 
- 
runUpdateQueryRuns the given UPDATE/INSERT/DELETE query, and returns the number of rows affected.- Throws:
- SQLException
 
- 
runPrepUpdateRuns the given UPDATE/INSERT/DELETE query as a prepared statement, after setting the arguments in the varargs list. Returns the number of rows affected.- Throws:
- SQLException
 
- 
getSeqGets the next value in a named integer sequence.- Throws:
- SQLException
 
- 
getSeqLike the other getSeq, but operates against a particular local db connection, which may be necessary if the sequence generation is part of a transaction.- Throws:
- SQLException
 
- 
runTransactionCreates a connection, and runs the given transaction. Transactions need to be serializable.- Throws:
- SQLException
 
 
-