Package org.apache.ibatis.type
Class EnumOrdinalTypeHandler<E extends java.lang.Enum<E>>
- java.lang.Object
-
- org.apache.ibatis.type.TypeReference<T>
-
- org.apache.ibatis.type.BaseTypeHandler<E>
-
- org.apache.ibatis.type.EnumOrdinalTypeHandler<E>
-
- All Implemented Interfaces:
TypeHandler<E>
public class EnumOrdinalTypeHandler<E extends java.lang.Enum<E>> extends BaseTypeHandler<E>
- Author:
- Clinton Begin
-
-
Field Summary
-
Fields inherited from class org.apache.ibatis.type.BaseTypeHandler
configuration
-
-
Constructor Summary
Constructors Constructor Description EnumOrdinalTypeHandler(java.lang.Class<E> type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EgetNullableResult(java.sql.CallableStatement cs, int columnIndex)EgetNullableResult(java.sql.ResultSet rs, int columnIndex)EgetNullableResult(java.sql.ResultSet rs, java.lang.String columnName)voidsetNonNullParameter(java.sql.PreparedStatement ps, int i, E parameter, JdbcType jdbcType)-
Methods inherited from class org.apache.ibatis.type.BaseTypeHandler
getResult, getResult, getResult, setConfiguration, setParameter
-
Methods inherited from class org.apache.ibatis.type.TypeReference
getRawType, toString
-
-
-
-
Constructor Detail
-
EnumOrdinalTypeHandler
public EnumOrdinalTypeHandler(java.lang.Class<E> type)
-
-
Method Detail
-
setNonNullParameter
public void setNonNullParameter(java.sql.PreparedStatement ps, int i, E parameter, JdbcType jdbcType) throws java.sql.SQLException- Specified by:
setNonNullParameterin classBaseTypeHandler<E extends java.lang.Enum<E>>- Throws:
java.sql.SQLException
-
getNullableResult
public E getNullableResult(java.sql.ResultSet rs, java.lang.String columnName) throws java.sql.SQLException
- Specified by:
getNullableResultin classBaseTypeHandler<E extends java.lang.Enum<E>>columnName- Colunm name, when configurationuseColumnLabelisfalse- Throws:
java.sql.SQLException
-
getNullableResult
public E getNullableResult(java.sql.ResultSet rs, int columnIndex) throws java.sql.SQLException
- Specified by:
getNullableResultin classBaseTypeHandler<E extends java.lang.Enum<E>>- Throws:
java.sql.SQLException
-
getNullableResult
public E getNullableResult(java.sql.CallableStatement cs, int columnIndex) throws java.sql.SQLException
- Specified by:
getNullableResultin classBaseTypeHandler<E extends java.lang.Enum<E>>- Throws:
java.sql.SQLException
-
-