Package org.springframework.jdbc.object
Class SqlOperation
java.lang.Object
org.springframework.jdbc.object.RdbmsOperation
org.springframework.jdbc.object.SqlOperation
- All Implemented Interfaces:
- InitializingBean
Operation object representing an SQL-based operation such as a query or update,
 as opposed to a stored procedure.
 
Configures a PreparedStatementCreatorFactory
 based on the declared parameters.
- Author:
- Rod Johnson, Juergen Hoeller
- 
Field SummaryFields inherited from class org.springframework.jdbc.object.RdbmsOperationlogger
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionprotected final voidOverridden method to configure the PreparedStatementCreatorFactory based on our declared parameters.protected ParsedSqlObtain a parsed representation of this operation's SQL statement.protected final PreparedStatementCreatornewPreparedStatementCreator(@Nullable Object @Nullable [] params) Return a PreparedStatementCreator to perform an operation with the given parameters.protected final PreparedStatementCreatornewPreparedStatementCreator(String sqlToUse, @Nullable Object @Nullable [] params) Return a PreparedStatementCreator to perform an operation with the given parameters.protected final PreparedStatementSetternewPreparedStatementSetter(@Nullable Object @Nullable [] params) Return a PreparedStatementSetter to perform an operation with the given parameters.protected voidHook method that subclasses may override to post-process compilation.Methods inherited from class org.springframework.jdbc.object.RdbmsOperationafterPropertiesSet, allowsUnusedParameters, checkCompiled, compile, declareParameter, getDeclaredParameters, getGeneratedKeysColumnNames, getJdbcTemplate, getResultSetType, getSql, isCompiled, isReturnGeneratedKeys, isUpdatableResults, resolveSql, setDataSource, setFetchSize, setGeneratedKeysColumnNames, setJdbcTemplate, setMaxRows, setParameters, setQueryTimeout, setResultSetType, setReturnGeneratedKeys, setSql, setTypes, setUpdatableResults, supportsLobParameters, validateNamedParameters, validateParameters
- 
Constructor Details- 
SqlOperationpublic SqlOperation()
 
- 
- 
Method Details- 
compileInternalprotected final void compileInternal()Overridden method to configure the PreparedStatementCreatorFactory based on our declared parameters.- Specified by:
- compileInternalin class- RdbmsOperation
 
- 
onCompileInternalprotected void onCompileInternal()Hook method that subclasses may override to post-process compilation. This implementation does nothing.- See Also:
 
- 
getParsedSqlObtain a parsed representation of this operation's SQL statement.Typically used for named parameter parsing. 
- 
newPreparedStatementSetterprotected final PreparedStatementSetter newPreparedStatementSetter(@Nullable Object @Nullable [] params) Return a PreparedStatementSetter to perform an operation with the given parameters.- Parameters:
- params- the parameter array (may be- null)
 
- 
newPreparedStatementCreatorprotected final PreparedStatementCreator newPreparedStatementCreator(@Nullable Object @Nullable [] params) Return a PreparedStatementCreator to perform an operation with the given parameters.- Parameters:
- params- the parameter array (may be- null)
 
- 
newPreparedStatementCreatorprotected final PreparedStatementCreator newPreparedStatementCreator(String sqlToUse, @Nullable Object @Nullable [] params) Return a PreparedStatementCreator to perform an operation with the given parameters.- 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)
 
 
-