public interface JdbcExpert
这个接口的实现类的实例会被 Nutz.Dao 长期持有,所有请保证其线程安全
Pojo createPojo(SqlType type)
type
- POJO 语句的 SQL 类型SqlType
ValueAdaptor getAdaptor(MappingField ef)
ef
- 实体数据库映射字段void setupEntityField(Connection conn, Entity<?> en)
实体类在解析的时候会用到这个函数
conn
- 数据库连接en
- 实体void formatQuery(DaoStatement daoStatement)
daoStatement
- Dao 语句Pojo fetchPojoId(Entity<?> en, MappingField idField)
boolean isSupportAutoIncrement()
boolean isSupportGeneratedKeys()
String evalFieldType(MappingField mf)
boolean addColumnNeedColumn()
boolean supportTimestampDefault()
void checkDataSource(Connection conn) throws SQLException
SQLException
Sql createIndexSql(Entity<?> en, EntityIndex index)
Sql createAddColumnSql(Entity<?> en, MappingField mf)
boolean canCommentWhenAddIndex()
List<String> getIndexNames(Entity<?> en, Connection conn) throws SQLException
SQLException
Copyright © 2017. All rights reserved.