Class SqlCall

java.lang.Object
org.springframework.jdbc.object.RdbmsOperation
org.springframework.jdbc.object.SqlCall
All Implemented Interfaces:
InitializingBean
Direct Known Subclasses:
StoredProcedure

public abstract class SqlCall extends RdbmsOperation
RdbmsOperation using a JdbcTemplate and representing an SQL-based call such as a stored procedure or a stored function.

Configures a CallableStatementCreatorFactory based on the declared parameters.

Author:
Rod Johnson, Thomas Risberg
See Also:
  • Constructor Details

  • Method Details

    • setFunction

      public void setFunction(boolean function)
      Set whether this call is for a function.
    • isFunction

      public boolean isFunction()
      Return whether this call is for a function.
    • setSqlReadyForUse

      public void setSqlReadyForUse(boolean sqlReadyForUse)
      Set whether the SQL can be used as is.
    • isSqlReadyForUse

      public boolean isSqlReadyForUse()
      Return whether the SQL can be used as is.
    • compileInternal

      protected final void compileInternal()
      Overridden method to configure the CallableStatementCreatorFactory based on our declared parameters.
      Specified by:
      compileInternal in class RdbmsOperation
      See Also:
    • onCompileInternal

      protected void onCompileInternal()
      Hook method that subclasses may override to react to compilation. This implementation does nothing.
    • getCallString

      @Nullable public String getCallString()
      Get the call string.
    • newCallableStatementCreator

      protected CallableStatementCreator newCallableStatementCreator(@Nullable Map<String,?> inParams)
      Return a CallableStatementCreator to perform an operation with these parameters.
      Parameters:
      inParams - parameters. May be null.
    • newCallableStatementCreator

      protected CallableStatementCreator newCallableStatementCreator(ParameterMapper inParamMapper)
      Return a CallableStatementCreator to perform an operation with the parameters returned from this ParameterMapper.
      Parameters:
      inParamMapper - parametermapper. May not be null.