public class BigDecimalNUMERICType extends Object implements TypeHandler<BigDecimal>
| Constructor and Description |
|---|
BigDecimalNUMERICType() |
| Modifier and Type | Method and Description |
|---|---|
BigDecimal |
get(CallableStatement cs,
int index) |
BigDecimal |
get(CallableStatement cs,
String parameterName) |
BigDecimal |
get(ResultSet rs,
int index)
从结果集里获取一个字段的值
|
BigDecimal |
get(ResultSet rs,
String columnLabel)
从结果集里获取一个字段的值
|
Class<BigDecimal> |
getDefaultJavaType()
类型
|
int |
getSqlType()
java.sql.Types的值
|
Object |
set(CallableStatement cs,
Object obj,
String parameterName) |
Object |
set(PreparedStatement stat,
Object obj,
int i)
为缓冲语句设置值
|
void |
update(ResultSet rs,
int columnIndex,
Object value) |
void |
update(ResultSet rs,
String columnLabel,
Object value)
为了支持悲观锁中的数据类型转换
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetSqlExpression, setColumnMapping, setDefaultJavaType, setSqlTypepublic BigDecimal get(ResultSet rs, String columnLabel) throws SQLException
TypeHandlerget in interface TypeHandler<BigDecimal>rs - 结果集columnLabel - 列名SQLExceptionpublic BigDecimal get(ResultSet rs, int index) throws SQLException
TypeHandlerget in interface TypeHandler<BigDecimal>rs - 结果集index - 索引SQLExceptionpublic BigDecimal get(CallableStatement cs, int index) throws SQLException
get in interface TypeHandler<BigDecimal>SQLExceptionpublic Object set(PreparedStatement stat, Object obj, int i) throws SQLException
TypeHandler一个值可以被设置到多个占位符中
set in interface TypeHandler<BigDecimal>stat - 缓冲语句obj - 值i - 占位符位置,从 1 开始SQLExceptionpublic Object set(CallableStatement cs, Object obj, String parameterName) throws SQLException
set in interface TypeHandler<BigDecimal>SQLExceptionpublic BigDecimal get(CallableStatement cs, String parameterName) throws SQLException
get in interface TypeHandler<BigDecimal>SQLExceptionpublic void update(ResultSet rs, String columnLabel, Object value) throws SQLException
TypeHandlerupdate in interface TypeHandler<BigDecimal>SQLExceptionpublic void update(ResultSet rs, int columnIndex, Object value) throws SQLException
update in interface TypeHandler<BigDecimal>SQLExceptionpublic int getSqlType()
TypeHandlergetSqlType in interface TypeHandler<BigDecimal>public Class<BigDecimal> getDefaultJavaType()
TypeHandlergetDefaultJavaType in interface TypeHandler<BigDecimal>Copyright © 2020. All rights reserved.