Java Code Examples for org.springframework.jdbc.core.ParameterMapper

The following examples show how to use org.springframework.jdbc.core.ParameterMapper. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: spring-analysis-note   Source File: StoredProcedure.java    License: MIT License 2 votes vote down vote up
/**
 * Execute the stored procedure. Subclasses should define a strongly typed
 * execute method (with a meaningful name) that invokes this method, passing in
 * a ParameterMapper that will populate the input map.  This allows mapping database
 * specific features since the ParameterMapper has access to the Connection object.
 * The execute method is also responsible for extracting typed values from the output map.
 * Subclass execute methods will often take domain objects as arguments and return values.
 * Alternatively, they can return void.
 * @param inParamMapper map of input parameters, keyed by name as in parameter
 * declarations. Output parameters need not (but can) be included in this map.
 * It is legal for map entries to be {@code null}, and this will produce the correct
 * behavior using a NULL argument to the stored procedure.
 * @return map of output params, keyed by name as in parameter declarations.
 * Output parameters will appear here, with their values after the
 * stored procedure has been called.
 */
public Map<String, Object> execute(ParameterMapper inParamMapper) throws DataAccessException {
	checkCompiled();
	return getJdbcTemplate().call(newCallableStatementCreator(inParamMapper), getDeclaredParameters());
}
 
Example 2
Source Project: spring-analysis-note   Source File: SqlCall.java    License: MIT License 2 votes vote down vote up
/**
 * Return a CallableStatementCreator to perform an operation
 * with the parameters returned from this ParameterMapper.
 * @param inParamMapper parametermapper. May not be {@code null}.
 */
protected CallableStatementCreator newCallableStatementCreator(ParameterMapper inParamMapper) {
	Assert.state(this.callableStatementFactory != null, "No CallableStatementFactory available");
	return this.callableStatementFactory.newCallableStatementCreator(inParamMapper);
}
 
Example 3
Source Project: java-technology-stack   Source File: StoredProcedure.java    License: MIT License 2 votes vote down vote up
/**
 * Execute the stored procedure. Subclasses should define a strongly typed
 * execute method (with a meaningful name) that invokes this method, passing in
 * a ParameterMapper that will populate the input map.  This allows mapping database
 * specific features since the ParameterMapper has access to the Connection object.
 * The execute method is also responsible for extracting typed values from the output map.
 * Subclass execute methods will often take domain objects as arguments and return values.
 * Alternatively, they can return void.
 * @param inParamMapper map of input parameters, keyed by name as in parameter
 * declarations. Output parameters need not (but can) be included in this map.
 * It is legal for map entries to be {@code null}, and this will produce the correct
 * behavior using a NULL argument to the stored procedure.
 * @return map of output params, keyed by name as in parameter declarations.
 * Output parameters will appear here, with their values after the
 * stored procedure has been called.
 */
public Map<String, Object> execute(ParameterMapper inParamMapper) throws DataAccessException {
	checkCompiled();
	return getJdbcTemplate().call(newCallableStatementCreator(inParamMapper), getDeclaredParameters());
}
 
Example 4
Source Project: java-technology-stack   Source File: SqlCall.java    License: MIT License 2 votes vote down vote up
/**
 * Return a CallableStatementCreator to perform an operation
 * with the parameters returned from this ParameterMapper.
 * @param inParamMapper parametermapper. May not be {@code null}.
 */
protected CallableStatementCreator newCallableStatementCreator(ParameterMapper inParamMapper) {
	Assert.state(this.callableStatementFactory != null, "No CallableStatementFactory available");
	return this.callableStatementFactory.newCallableStatementCreator(inParamMapper);
}
 
Example 5
Source Project: lams   Source File: StoredProcedure.java    License: GNU General Public License v2.0 2 votes vote down vote up
/**
 * Execute the stored procedure. Subclasses should define a strongly typed
 * execute method (with a meaningful name) that invokes this method, passing in
 * a ParameterMapper that will populate the input map.  This allows mapping database
 * specific features since the ParameterMapper has access to the Connection object.
 * The execute method is also responsible for extracting typed values from the output map.
 * Subclass execute methods will often take domain objects as arguments and return values.
 * Alternatively, they can return void.
 * @param inParamMapper map of input parameters, keyed by name as in parameter
 * declarations. Output parameters need not (but can) be included in this map.
 * It is legal for map entries to be {@code null}, and this will produce the correct
 * behavior using a NULL argument to the stored procedure.
 * @return map of output params, keyed by name as in parameter declarations.
 * Output parameters will appear here, with their values after the
 * stored procedure has been called.
 */
public Map<String, Object> execute(ParameterMapper inParamMapper) throws DataAccessException {
	checkCompiled();
	return getJdbcTemplate().call(newCallableStatementCreator(inParamMapper), getDeclaredParameters());
}
 
Example 6
Source Project: lams   Source File: SqlCall.java    License: GNU General Public License v2.0 2 votes vote down vote up
/**
 * Return a CallableStatementCreator to perform an operation
 * with the parameters returned from this ParameterMapper.
 * @param inParamMapper parametermapper. May not be {@code null}.
 */
protected CallableStatementCreator newCallableStatementCreator(ParameterMapper inParamMapper) {
	return this.callableStatementFactory.newCallableStatementCreator(inParamMapper);
}
 
Example 7
Source Project: spring4-understanding   Source File: StoredProcedure.java    License: Apache License 2.0 2 votes vote down vote up
/**
 * Execute the stored procedure. Subclasses should define a strongly typed
 * execute method (with a meaningful name) that invokes this method, passing in
 * a ParameterMapper that will populate the input map.  This allows mapping database
 * specific features since the ParameterMapper has access to the Connection object.
 * The execute method is also responsible for extracting typed values from the output map.
 * Subclass execute methods will often take domain objects as arguments and return values.
 * Alternatively, they can return void.
 * @param inParamMapper map of input parameters, keyed by name as in parameter
 * declarations. Output parameters need not (but can) be included in this map.
 * It is legal for map entries to be {@code null}, and this will produce the correct
 * behavior using a NULL argument to the stored procedure.
 * @return map of output params, keyed by name as in parameter declarations.
 * Output parameters will appear here, with their values after the
 * stored procedure has been called.
 */
public Map<String, Object> execute(ParameterMapper inParamMapper) throws DataAccessException {
	checkCompiled();
	return getJdbcTemplate().call(newCallableStatementCreator(inParamMapper), getDeclaredParameters());
}
 
Example 8
Source Project: spring4-understanding   Source File: SqlCall.java    License: Apache License 2.0 2 votes vote down vote up
/**
 * Return a CallableStatementCreator to perform an operation
 * with the parameters returned from this ParameterMapper.
 * @param inParamMapper parametermapper. May not be {@code null}.
 */
protected CallableStatementCreator newCallableStatementCreator(ParameterMapper inParamMapper) {
	return this.callableStatementFactory.newCallableStatementCreator(inParamMapper);
}
 
Example 9
Source Project: effectivejava   Source File: StoredProcedure.java    License: Apache License 2.0 2 votes vote down vote up
/**
 * Execute the stored procedure. Subclasses should define a strongly typed
 * execute method (with a meaningful name) that invokes this method, passing in
 * a ParameterMapper that will populate the input map.  This allows mapping database
 * specific features since the ParameterMapper has access to the Connection object.
 * The execute method is also responsible for extracting typed values from the output map.
 * Subclass execute methods will often take domain objects as arguments and return values.
 * Alternatively, they can return void.
 * @param inParamMapper map of input parameters, keyed by name as in parameter
 * declarations. Output parameters need not (but can) be included in this map.
 * It is legal for map entries to be {@code null}, and this will produce the correct
 * behavior using a NULL argument to the stored procedure.
 * @return map of output params, keyed by name as in parameter declarations.
 * Output parameters will appear here, with their values after the
 * stored procedure has been called.
 */
public Map<String, Object> execute(ParameterMapper inParamMapper) throws DataAccessException {
	checkCompiled();
	return getJdbcTemplate().call(newCallableStatementCreator(inParamMapper), getDeclaredParameters());
}
 
Example 10
Source Project: effectivejava   Source File: SqlCall.java    License: Apache License 2.0 2 votes vote down vote up
/**
 * Return a CallableStatementCreator to perform an operation
 * with the parameters returned from this ParameterMapper.
 * @param inParamMapper parametermapper. May not be {@code null}.
 */
protected CallableStatementCreator newCallableStatementCreator(ParameterMapper inParamMapper) {
	return this.callableStatementFactory.newCallableStatementCreator(inParamMapper);
}