java.lang.Object | |
↳ | org.springframework.jdbc.core.PreparedStatementCreatorFactory |
Helper class that efficiently creates multiple PreparedStatementCreator
objects with different parameters based on a SQL statement and a single
set of parameter declarations.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Create a new factory.
| |||||||||||
Create a new factory with the given SQL and JDBC types.
| |||||||||||
Create a new factory with the given SQL and parameters.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Add a new declared parameter.
| |||||||||||
Return a new PreparedStatementCreator for the given parameters.
| |||||||||||
Return a new PreparedStatementCreator for the given parameters.
| |||||||||||
Return a new PreparedStatementCreator for the given parameters.
| |||||||||||
Return a new PreparedStatementSetter for the given parameters.
| |||||||||||
Return a new PreparedStatementSetter for the given parameters.
| |||||||||||
Set the column names of the auto-generated keys.
| |||||||||||
Specify the NativeJdbcExtractor to use for unwrapping PreparedStatements, if any.
| |||||||||||
Set whether to use prepared statements that return a specific type of ResultSet.
| |||||||||||
Set whether prepared statements should be capable of returning auto-generated keys.
| |||||||||||
Set whether to use prepared statements capable of returning updatable ResultSets.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Create a new factory. Will need to add parameters via the
addParameter(SqlParameter)
method or have no parameters.
Create a new factory with the given SQL and JDBC types.
sql | SQL to execute |
---|---|
types | int array of JDBC types |
Create a new factory with the given SQL and parameters.
sql | SQL |
---|---|
declaredParameters | list of SqlParameter objects |
Add a new declared parameter.
Order of parameter addition is significant.
param | the parameter to add to the list of declared parameters |
---|
Return a new PreparedStatementCreator for the given parameters.
params | the parameter array (may be null )
|
---|
Return a new PreparedStatementCreator for the given parameters.
params | list of parameters (may be null )
|
---|
Return a new PreparedStatementCreator for the given parameters.
sqlToUse | the actual SQL statement to use (if different from the factory's, for example because of named parameter expanding) |
---|---|
params | the parameter array (may be null )
|
Return a new PreparedStatementSetter for the given parameters.
params | the parameter array (may be null )
|
---|
Return a new PreparedStatementSetter for the given parameters.
params | list of parameters (may be null )
|
---|
Set the column names of the auto-generated keys.
Specify the NativeJdbcExtractor to use for unwrapping PreparedStatements, if any.
Set whether to use prepared statements that return a specific type of ResultSet.
resultSetType | the ResultSet type |
---|
Set whether prepared statements should be capable of returning auto-generated keys.
Set whether to use prepared statements capable of returning updatable ResultSets.