public abstract class TypeHandlerAdapter<T>
extends org.apache.ibatis.type.BaseTypeHandler<T>
| 构造器和说明 |
|---|
TypeHandlerAdapter() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected abstract T |
convertValue(Object columnValue)
解析数据库字段值,转成java对象值
|
protected abstract Object |
getFillValue(T defaultValue)
保存到数据库的值
|
T |
getNullableResult(CallableStatement cs,
int columnIndex) |
T |
getNullableResult(ResultSet rs,
int columnIndex) |
T |
getNullableResult(ResultSet rs,
String columnName) |
void |
setNonNullParameter(PreparedStatement ps,
int i,
T parameter,
org.apache.ibatis.type.JdbcType jdbcType) |
protected void |
setNullParameter(PreparedStatement ps,
int i,
T parameter,
org.apache.ibatis.type.JdbcType jdbcType) |
void |
setParameter(PreparedStatement ps,
int i,
T parameter,
org.apache.ibatis.type.JdbcType jdbcType) |
protected void |
setParameterDefault(PreparedStatement ps,
int i,
T parameter,
org.apache.ibatis.type.JdbcType jdbcType)
setParameter默认行为
|
protected void |
setParameterValue(PreparedStatement ps,
int i,
T parameter,
org.apache.ibatis.type.JdbcType jdbcType) |
protected abstract T convertValue(Object columnValue)
columnValue - public T getNullableResult(ResultSet rs, String columnName) throws SQLException
getNullableResult 在类中 org.apache.ibatis.type.BaseTypeHandler<T>SQLExceptionpublic T getNullableResult(ResultSet rs, int columnIndex) throws SQLException
getNullableResult 在类中 org.apache.ibatis.type.BaseTypeHandler<T>SQLExceptionpublic T getNullableResult(CallableStatement cs, int columnIndex) throws SQLException
getNullableResult 在类中 org.apache.ibatis.type.BaseTypeHandler<T>SQLExceptionpublic void setParameter(PreparedStatement ps, int i, T parameter, org.apache.ibatis.type.JdbcType jdbcType) throws SQLException
setParameter 在接口中 org.apache.ibatis.type.TypeHandler<T>setParameter 在类中 org.apache.ibatis.type.BaseTypeHandler<T>SQLExceptionprotected void setNullParameter(PreparedStatement ps, int i, T parameter, org.apache.ibatis.type.JdbcType jdbcType) throws SQLException
SQLExceptionpublic void setNonNullParameter(PreparedStatement ps, int i, T parameter, org.apache.ibatis.type.JdbcType jdbcType) throws SQLException
setNonNullParameter 在类中 org.apache.ibatis.type.BaseTypeHandler<T>SQLExceptionprotected void setParameterValue(PreparedStatement ps, int i, T parameter, org.apache.ibatis.type.JdbcType jdbcType) throws SQLException
SQLExceptionprotected void setParameterDefault(PreparedStatement ps, int i, T parameter, org.apache.ibatis.type.JdbcType jdbcType) throws SQLException
ps - i - parameter - jdbcType - SQLExceptionCopyright © 2018. All Rights Reserved.