public interface JdbcOperations
The design of this interface was heavily influenced by the
FluentJdbc abstraction in the Spring Framework, however it
differs significantly, particularly in the manner in which queries and
updates are invoked. Nonetheless, users of FluentJdbc should
find it familiar enough to easily learn.
| Modifier and Type | Method and Description |
|---|---|
JdbcCall |
call(SQLSource source)
Creates a call operation.
|
JdbcCall |
call(String sql)
Creates a call operation.
|
void |
execute(SQLSource source)
Executes a single SQL (DDL) statement.
|
void |
execute(String sql)
Executes a single SQL (DDL) statement.
|
void |
executeScript(SQLSource source)
Executes the sequence of SQL statements produced by the given source.
|
JdbcQuery<Void> |
query()
Creates a query operation.
|
<T> JdbcQuery<T> |
queryForType(Class<T> type)
Creates a query operation for objects of a given type.
|
JdbcUpdate |
update()
Creates an update operation.
|
void execute(String sql)
sql - the SQL statement to executevoid execute(SQLSource source)
source - source for the SQL statement to executevoid executeScript(SQLSource source)
source - source of the SQL statements to executeJdbcQuery<Void> query()
This is a synonym for queryForType(Class) with Void
as the specified type. A query obtained via this method is typically
configured to use a ResultSetHandler to process returned rows.
<T> JdbcQuery<T> queryForType(Class<T> type)
type - subject type of the queryT.JdbcUpdate update()
JdbcCall call(String sql)
sql - SQL call statementCopyright © 2014–2015 Carl Harris, Jr. All rights reserved.