mybatis typehandler

默认类型处理器(3.4.6)

类型处理器 Java类型 JDBC类型
ByteTypeHandler byte NUMERIC, BYTE
ShortTypeHandler short NUMERIC, SHORT INTEGER
IntegerTypeHandler int NUMERIC, INTEGER
LongTypeHandler long NUMERIC, LONG INTEGER
FloatTypeHandler float NUMERIC, FLOAT
DoubleTypeHandler double NUMERIC, DOUBLE
BooleanTypeHandler boolean BOOLEAN
ByteTypeHandler java.lang.Byte NUMERIC, BYTE
ShortTypeHandler java.lang.Short NUMERIC, SHORT INTEGER
IntegerTypeHandler java.lang.Integer NUMERIC, INTEGER
LongTypeHandler java.lang.Long NUMERIC, LONG INTEGER
FloatTypeHandler java.lang.Float NUMERIC, FLOAT
DoubleTypeHandler java.lang.Double NUMERIC, DOUBLE
BooleanTypeHandler java.lang.Boolean BOOLEAN
StringTypeHandler java.lang.String CHAR, VARCHAR
BigDecimalTypeHandler java.math.BigDecimal NUMERIC, DECIMAL
LocalDateTypeHandler java.time.LocalDate DATE
LocalTimeTypeHandler java.time.LocalTime TIME
LocalDateTimeTypeHandler java.time.LocalDateTime TIMESTAMP
OffsetTimeTypeHandler java.time.OffsetTime TIME
OffsetDateTimeTypeHandler java.time.OffsetDateTime TIMESTAMP
ZonedDateTimeTypeHandler java.time.ZonedDateTime TIMESTAMP
InstantTypeHandler java.time.Instant TIMESTAMP
YearTypeHandler java.time.Year INTEGER
MonthTypeHandler java.time.Month INTEGER
YearMonthTypeHandler java.time.YearMonth VARCHAR, LONGVARCHAR
JapaneseDateTypeHandler java.time.chrono.JapaneseDate DATE
DateTypeHandler java.util.Date TIMESTAMP
DateOnlyTypeHandler java.util.Date DATE
TimeOnlyTypeHandler java.util.Date TIME
SqlTimestampTypeHandler java.sql.Timestamp TIMESTAMP
SqlDateTypeHandler java.sql.Date DATE
SqlTimeTypeHandler java.sql.Time TIME
EnumTypeHandler Java枚举类型(存名称) VARCHAR
EnumOrdinalTypeHandler Java枚举类型(存索引) NUMERIC, DOUBLE

// 待补充

你可能感兴趣的:(mybatis typehandler)