public class ArgumentPreparedStatementSetter extends Object implements PreparedStatementSetter
Simple adapter for PreparedStatementSetter that applies a given array of arguments.
@author online.sanen
Date:2018年10月14日
Time:下午7:01:35
| 构造器和说明 |
|---|
ArgumentPreparedStatementSetter(Object[] args)
Create a new ArgPreparedStatementSetter for the given arguments.
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
doSetValue(PreparedStatement ps,
int parameterPosition,
Object argValue)
Set the value for prepared statements specified parameter index using the
passed in value.
|
void |
setValues(PreparedStatement ps)
Set parameter values on the given PreparedStatement.
|
public ArgumentPreparedStatementSetter(Object[] args)
args - the arguments to setpublic void setValues(PreparedStatement ps) throws SQLException
PreparedStatementSettersetValues 在接口中 PreparedStatementSetterps - the PreparedStatement to invoke setter methods onSQLException - if a SQLException is encountered
(i.e. there is no need to catch SQLException)protected void doSetValue(PreparedStatement ps, int parameterPosition, Object argValue) throws SQLException
ps - parameterPosition - argValue - SQLExceptionCopyright © 2023. All rights reserved.