A B C D E F G H I J K L M N O P Q R S T U V W 

A

abort(Executor) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
AbstractDataSource - cn.hutool.db.ds.simple中的类
数据源抽象实现
AbstractDataSource() - 类 的构造器cn.hutool.db.ds.simple.AbstractDataSource
 
AbstractDb - cn.hutool.db中的类
抽象数据库操作类
通过给定的数据源执行给定SQL或者给定数据源和方言,执行相应的CRUD操作
提供抽象方法getConnection和closeConnection,用于自定义数据库连接的打开和关闭
AbstractDb(DataSource, Dialect) - 类 的构造器cn.hutool.db.AbstractDb
构造
AbstractDSFactory - cn.hutool.db.ds中的类
抽象数据源工厂
此工厂抽象类用于实现数据源的缓存,当用户多次调用AbstractDSFactory.getDataSource(String) 时,工厂只需创建一次即可。
AbstractDSFactory(String, Class<? extends DataSource>, Setting) - 类 的构造器cn.hutool.db.ds.AbstractDSFactory
构造
ActiveEntity - cn.hutool.db中的类
动态实体类
提供了针对自身实体的增删改方法
ActiveEntity() - 类 的构造器cn.hutool.db.ActiveEntity
构造
ActiveEntity(String) - 类 的构造器cn.hutool.db.ActiveEntity
构造
ActiveEntity(Entity) - 类 的构造器cn.hutool.db.ActiveEntity
构造
ActiveEntity(Db, String) - 类 的构造器cn.hutool.db.ActiveEntity
构造
ActiveEntity(Db, Entity) - 类 的构造器cn.hutool.db.ActiveEntity
构造
add() - 类 中的方法cn.hutool.db.ActiveEntity
根据Entity中现有字段条件从数据库中增加一条数据
add(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
添加
addBatch(String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
addBatch() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
addFieldNames(String...) - 类 中的方法cn.hutool.db.ActiveEntity
 
addFieldNames(String...) - 类 中的方法cn.hutool.db.Entity
添加字段列表
addForGeneratedKey(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
添加
addForGeneratedKeys(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
添加
addOrder(Order...) - 类 中的方法cn.hutool.db.Page
设置排序
addOrUpdate(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
增加或者更新实体
addPk(String) - 类 中的方法cn.hutool.db.meta.Table
添加主键
AnsiSqlDialect - cn.hutool.db.dialect.impl中的类
ANSI SQL 方言
AnsiSqlDialect() - 类 的构造器cn.hutool.db.dialect.impl.AnsiSqlDialect
 
append(Object) - 类 中的方法cn.hutool.db.sql.SqlBuilder
追加SQL其它部分片段

B

BeanHandler<E> - cn.hutool.db.handler中的类
Bean对象处理器,只处理第一条数据
BeanHandler(Class<E>) - 类 的构造器cn.hutool.db.handler.BeanHandler
 
BeanListHandler<E> - cn.hutool.db.handler中的类
结果集处理类 ,处理出的结果为Bean列表
BeanListHandler(Class<E>) - 类 的构造器cn.hutool.db.handler.BeanListHandler
构造
beginTransaction() - 类 中的方法cn.hutool.db.Session
开始事务
blobToStr(Blob, Charset) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
Blob字段值转字符串
build() - 类 中的方法cn.hutool.db.sql.SqlBuilder
构建,默认打印SQL日志
buildConditions(Entity) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
通过实体对象构建条件对象
buildEqualsWhere(Entity, List<Object>) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
构件相等条件的where语句
如果没有条件语句,泽返回空串,表示没有条件
buildLikeValue(String, Condition.LikeType, boolean) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
创建LIKE语句中的值,创建的结果为: 1、LikeType.StartWith: %value 2、LikeType.EndWith: value% 3、LikeType.Contains: %value% 如果withLikeKeyword为true,则结果为: 1、LikeType.StartWith: LIKE %value 2、LikeType.EndWith: LIKE value% 3、LikeType.Contains: LIKE %value%

C

C3p0DSFactory - cn.hutool.db.ds.c3p0中的类
Druid数据源工厂类
C3p0DSFactory() - 类 的构造器cn.hutool.db.ds.c3p0.C3p0DSFactory
构造,使用默认配置
C3p0DSFactory(Setting) - 类 的构造器cn.hutool.db.ds.c3p0.C3p0DSFactory
构造
call(Connection, String, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行调用存储过程
此方法不会关闭Connection
callQuery(Connection, String, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行调用存储过程
此方法不会关闭Connection
cancel() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
checkTransactionSupported(Connection) - 类 中的方法cn.hutool.db.AbstractDb
检查数据库是否支持事务,此项检查同一个数据源只检查一次,如果不支持抛出DbRuntimeException异常
checkValueNull() - 类 中的方法cn.hutool.db.sql.Condition
检查值是否为null,如果为null转换为 "IS NULL"形式
clearBatch() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
clearParameters() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
clearWarnings() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
clearWarnings() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
clobToStr(Clob) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
Clob字段值转字符串
clone() - 类 中的方法cn.hutool.db.ActiveEntity
 
clone() - 类 中的方法cn.hutool.db.Entity
 
close(Object...) - 类 中的静态方法cn.hutool.db.DbUtil
连续关闭一系列的SQL相关对象
这些对象必须按照顺序关闭,否则会出错。
close(String) - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
 
close() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
close() - 类 中的方法cn.hutool.db.ds.DSFactory
关闭默认数据源(空组)
close(String) - 类 中的方法cn.hutool.db.ds.DSFactory
关闭对应数据源
close() - 类 中的方法cn.hutool.db.ds.pooled.PooledConnection
重写关闭连接,实际操作是归还到连接池中
close() - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
 
close() - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
close() - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
 
close() - 类 中的方法cn.hutool.db.nosql.redis.RedisDS
 
close() - 类 中的方法cn.hutool.db.Session
 
close() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
close(DataSource) - 枚举 中的方法cn.hutool.db.ThreadLocalConnection
关闭数据库,并从线程池中移除
close(DataSource) - 类 中的方法cn.hutool.db.ThreadLocalConnection.GroupedConnection
关闭并移除Connection
如果处于事务中,则不进行任何操作
closeAll() - 类 中的静态方法cn.hutool.db.nosql.mongo.MongoFactory
关闭全部连接
closeConnection(Connection) - 类 中的方法cn.hutool.db.AbstractDb
关闭连接
自定义关闭连接有利于自定义回收连接机制,或者不关闭
closeConnection(Connection) - 类 中的方法cn.hutool.db.Db
 
closeConnection(Connection) - 类 中的方法cn.hutool.db.Session
 
closeConnection(Connection) - 类 中的方法cn.hutool.db.SqlRunner
已过时。
 
closeOnCompletion() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
cn.hutool.db - 程序包 cn.hutool.db
Hutool-db是一个在JDBC基础上封装的数据库操作工具类,通过包装,使用ActiveRecord思想操作数据库。
cn.hutool.db.dialect - 程序包 cn.hutool.db.dialect
数据库方言封装,包括数据库方言以及方言自动识别等
cn.hutool.db.dialect.impl - 程序包 cn.hutool.db.dialect.impl
数据库方言实现,包括MySQL、Oracle、PostgreSQL、Sqlite3、H2、SqlServer2012等
cn.hutool.db.ds - 程序包 cn.hutool.db.ds
数据源封装,对各类数据库连接池的封装
cn.hutool.db.ds.c3p0 - 程序包 cn.hutool.db.ds.c3p0
C3P0封装
cn.hutool.db.ds.dbcp - 程序包 cn.hutool.db.ds.dbcp
DBCP封装
cn.hutool.db.ds.druid - 程序包 cn.hutool.db.ds.druid
Druid封装
cn.hutool.db.ds.hikari - 程序包 cn.hutool.db.ds.hikari
Hikari封装
cn.hutool.db.ds.jndi - 程序包 cn.hutool.db.ds.jndi
JNDI封装
cn.hutool.db.ds.pooled - 程序包 cn.hutool.db.ds.pooled
Hutool对连接池的简单实现
cn.hutool.db.ds.simple - 程序包 cn.hutool.db.ds.simple
JDBC中DriverManager简易封装
cn.hutool.db.ds.tomcat - 程序包 cn.hutool.db.ds.tomcat
Tomcat-Pool封装
cn.hutool.db.handler - 程序包 cn.hutool.db.handler
JDBC结果集(ResultSet)转换封装,通过实现RsHandler接口,将ResultSet转换为我们想要的数据类型
cn.hutool.db.meta - 程序包 cn.hutool.db.meta
JDBC数据表元数据信息封装,包括表结构、列信息的封装,入口为MetaUtil
cn.hutool.db.nosql.mongo - 程序包 cn.hutool.db.nosql.mongo
MongoDB数据库操作的封装
cn.hutool.db.nosql.redis - 程序包 cn.hutool.db.nosql.redis
Redis(Jedis)数据库操作的封装
cn.hutool.db.sql - 程序包 cn.hutool.db.sql
SQL语句和Statement构建封装
cn.hutool.db.transaction - 程序包 cn.hutool.db.transaction
事务相关类和操作
Column - cn.hutool.db.meta中的类
数据库表的列信息
Column() - 类 的构造器cn.hutool.db.meta.Column
构造
Column(String, ResultSet) - 类 的构造器cn.hutool.db.meta.Column
构造
commit() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
commit() - 类 中的方法cn.hutool.db.Session
提交事务
Condition - cn.hutool.db.sql中的类
条件对象
Condition() - 类 的构造器cn.hutool.db.sql.Condition
构造
Condition(boolean) - 类 的构造器cn.hutool.db.sql.Condition
构造
Condition(String, Object) - 类 的构造器cn.hutool.db.sql.Condition
构造,使用等于表达式(运算符是=)
Condition(String, String, Object) - 类 的构造器cn.hutool.db.sql.Condition
构造
Condition(String, String, Condition.LikeType) - 类 的构造器cn.hutool.db.sql.Condition
构造
Condition.LikeType - cn.hutool.db.sql中的枚举
SQL中 LIKE 语句查询方式
ConnectionWraper - cn.hutool.db.ds.pooled中的类
连接包装,用于丰富功能
ConnectionWraper() - 类 的构造器cn.hutool.db.ds.pooled.ConnectionWraper
 
count(Entity) - 类 中的方法cn.hutool.db.AbstractDb
结果的条目数
count(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
满足条件的数据条目数量
count(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
结果的条目数
create() - 类 中的静态方法cn.hutool.db.ActiveEntity
创建ActiveEntity
create(String) - 类 中的静态方法cn.hutool.db.ActiveEntity
创建ActiveEntity
create(Setting) - 类 中的静态方法cn.hutool.db.ds.DSFactory
创建数据源实现工厂
此方法通过“试错”方式查找引入项目的连接池库,按照优先级寻找,一旦寻找到则创建对应的数据源工厂
连接池优先级:Hikari > Druid > Tomcat > Dbcp > C3p0 > Hutool Pooled
create() - 类 中的静态方法cn.hutool.db.Entity
创建Entity
create(String) - 类 中的静态方法cn.hutool.db.Entity
创建Entity
create(Class<E>) - 类 中的静态方法cn.hutool.db.handler.BeanHandler
创建一个 BeanHandler对象
create(Class<E>) - 类 中的静态方法cn.hutool.db.handler.BeanListHandler
创建一个 BeanListHandler对象
create() - 类 中的静态方法cn.hutool.db.handler.EntityHandler
创建一个 EntityHandler对象
create() - 类 中的静态方法cn.hutool.db.handler.EntityListHandler
创建一个 EntityListHandler对象
create() - 类 中的静态方法cn.hutool.db.handler.EntitySetHandler
创建一个 EntityHandler对象
create() - 类 中的静态方法cn.hutool.db.handler.NumberHandler
创建一个 NumberHandler对象
create(PageResult<Entity>) - 类 中的静态方法cn.hutool.db.handler.PageResultHandler
创建一个 EntityHandler对象
结果集根据给定的分页对象查询数据库,填充结果
create() - 类 中的静态方法cn.hutool.db.handler.StringHandler
创建一个 NumberHandler对象
create(String, ResultSet) - 类 中的静态方法cn.hutool.db.meta.Column
创建列对象
create(String) - 类 中的静态方法cn.hutool.db.meta.Table
 
create() - 类 中的静态方法cn.hutool.db.nosql.redis.RedisDS
创建RedisDS,使用默认配置文件,默认分组
create(String) - 类 中的静态方法cn.hutool.db.nosql.redis.RedisDS
创建RedisDS,使用默认配置文件
create(Setting, String) - 类 中的静态方法cn.hutool.db.nosql.redis.RedisDS
创建RedisDS
create() - 类 中的静态方法cn.hutool.db.Session
创建默认数据源会话
create(String) - 类 中的静态方法cn.hutool.db.Session
创建会话
create(DataSource) - 类 中的静态方法cn.hutool.db.Session
创建会话
create() - 类 中的静态方法cn.hutool.db.sql.SqlBuilder
创建SQL构建器
create(Wrapper) - 类 中的静态方法cn.hutool.db.sql.SqlBuilder
创建SQL构建器
create(Dialect) - 类 中的静态方法cn.hutool.db.SqlConnRunner
实例化一个新的SQL运行对象
create(DataSource) - 类 中的静态方法cn.hutool.db.SqlConnRunner
实例化一个新的SQL运行对象
create(String) - 类 中的静态方法cn.hutool.db.SqlConnRunner
实例化一个新的SQL运行对象
create() - 类 中的静态方法cn.hutool.db.SqlRunner
已过时。
创建SqlRunner
使用默认数据源,自动探测数据库连接池
create(String) - 类 中的静态方法cn.hutool.db.SqlRunner
已过时。
创建SqlRunner
使用默认数据源,自动探测数据库连接池
create(DataSource) - 类 中的静态方法cn.hutool.db.SqlRunner
已过时。
创建SqlRunner
会根据数据源连接的元信息识别目标数据库类型,进而使用合适的数据源
create(DataSource, Dialect) - 类 中的静态方法cn.hutool.db.SqlRunner
已过时。
创建SqlRunner
create(DataSource, String) - 类 中的静态方法cn.hutool.db.SqlRunner
已过时。
创建SqlRunner
createArrayOf(String, Object[]) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createBlob() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createBlob(Connection, InputStream, boolean) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
创建Blob对象
createBlob(Connection, byte[]) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
创建Blob对象
createClob() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
创建新的DataSource
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.c3p0.C3p0DSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.dbcp.DbcpDSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.druid.DruidDSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.hikari.HikariDSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.jndi.JndiDSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.pooled.PooledDSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.simple.SimpleDSFactory
 
createDataSource(String, String, String, String, Setting) - 类 中的方法cn.hutool.db.ds.tomcat.TomcatDSFactory
 
createLimitedEntity(DataSource, String) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
创建带有字段限制的Entity对象
此方法读取数据库中对应表的字段列表,加入到Entity中,当Entity被设置内容时,会忽略对应表字段外的所有KEY
createNClob() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createSQLXML() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createStatement() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createStatement(int, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createStatement(int, int, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
createStruct(String, Object[]) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 

D

DaoTemplate - cn.hutool.db中的类
数据访问层模板
此模板用于简化对指定表的操作,简化的操作如下:
1、在初始化时指定了表名,CRUD操作时便不需要表名
2、在初始化时指定了主键,某些需要主键的操作便不需要指定主键类型
DaoTemplate(String) - 类 的构造器cn.hutool.db.DaoTemplate
构造,此构造需要自定义SqlRunner,主键默认为id
DaoTemplate(String, String) - 类 的构造器cn.hutool.db.DaoTemplate
构造,使用默认的池化连接池,读取默认配置文件的空分组,适用于只有一个数据库的情况
DaoTemplate(String, DataSource) - 类 的构造器cn.hutool.db.DaoTemplate
 
DaoTemplate(String, String, DataSource) - 类 的构造器cn.hutool.db.DaoTemplate
构造
DaoTemplate(String, String, Db) - 类 的构造器cn.hutool.db.DaoTemplate
构造
dataSourceName - 类 中的变量cn.hutool.db.ds.DSFactory
数据源名
DataSourceWrapper - cn.hutool.db.ds中的类
DataSource 数据源实现包装,通过包装,提供基本功能外的额外功能和参数持有,包括: 1.
DataSourceWrapper(DataSource, String) - 类 的构造器cn.hutool.db.ds.DataSourceWrapper
构造
db - 类 中的变量cn.hutool.db.DaoTemplate
SQL运行器
Db - cn.hutool.db中的类
数据库操作类
通过给定的数据源执行给定SQL或者给定数据源和方言,执行相应的CRUD操作
Db(DataSource) - 类 的构造器cn.hutool.db.Db
构造,从DataSource中识别方言
Db(DataSource, String) - 类 的构造器cn.hutool.db.Db
构造
Db(DataSource, Dialect) - 类 的构造器cn.hutool.db.Db
构造
DbConfig - cn.hutool.db.ds.pooled中的类
数据库配置
DbConfig() - 类 的构造器cn.hutool.db.ds.pooled.DbConfig
 
DbConfig(String, String, String) - 类 的构造器cn.hutool.db.ds.pooled.DbConfig
构造
DbcpDSFactory - cn.hutool.db.ds.dbcp中的类
DBCP2数据源工厂类
DbcpDSFactory() - 类 的构造器cn.hutool.db.ds.dbcp.DbcpDSFactory
 
DbcpDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.dbcp.DbcpDSFactory
 
DbRuntimeException - cn.hutool.db中的异常错误
数据库异常
DbRuntimeException(Throwable) - 异常错误 的构造器cn.hutool.db.DbRuntimeException
 
DbRuntimeException(String) - 异常错误 的构造器cn.hutool.db.DbRuntimeException
 
DbRuntimeException(String, Object...) - 异常错误 的构造器cn.hutool.db.DbRuntimeException
 
DbRuntimeException(String, Throwable) - 异常错误 的构造器cn.hutool.db.DbRuntimeException
 
DbRuntimeException(Throwable, String, Object...) - 异常错误 的构造器cn.hutool.db.DbRuntimeException
 
DbSetting - cn.hutool.db.ds.pooled中的类
数据库配置文件类,此类对应一个数据库配置文件
DbSetting() - 类 的构造器cn.hutool.db.ds.pooled.DbSetting
构造
DbSetting(Setting) - 类 的构造器cn.hutool.db.ds.pooled.DbSetting
构造
DbUtil - cn.hutool.db中的类
数据库操作工具类
DbUtil() - 类 的构造器cn.hutool.db.DbUtil
 
DEFAULT_DB_CONFIG_PATH - 类 中的静态变量cn.hutool.db.ds.pooled.DbSetting
默认的数据库连接配置文件路径
DEFAULT_DB_CONFIG_PATH - 类 中的静态变量cn.hutool.db.ds.simple.SimpleDataSource
默认的数据库连接配置文件路径
DEFAULT_PAGE_SIZE - 类 中的静态变量cn.hutool.db.Page
 
DEFAULT_PAGE_SIZE - 类 中的静态变量cn.hutool.db.PageResult
 
del(String, String, Object) - 类 中的方法cn.hutool.db.AbstractDb
删除数据
del(Entity) - 类 中的方法cn.hutool.db.AbstractDb
删除数据
del() - 类 中的方法cn.hutool.db.ActiveEntity
根据现有Entity中的条件删除与之匹配的数据库记录
del(T) - 类 中的方法cn.hutool.db.DaoTemplate
删除
del(String, T) - 类 中的方法cn.hutool.db.DaoTemplate
删除
del(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
删除
del(String...) - 类 中的方法cn.hutool.db.nosql.redis.RedisDS
从Redis中删除多个值
del(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
删除数据
此方法不会关闭Connection
delete(String) - 类 中的方法cn.hutool.db.sql.SqlBuilder
删除
destroy() - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
 
destroy() - 类 中的方法cn.hutool.db.ds.DSFactory
销毁工厂类,关闭所有数据源
Dialect - cn.hutool.db.dialect中的接口
SQL方言,不同的数据库由于在某些SQL上有所区别,故为每种数据库配置不同的方言。
DialectFactory - cn.hutool.db.dialect中的类
方言工厂类
dialectName() - 接口 中的方法cn.hutool.db.dialect.Dialect
方言名
DialectName - cn.hutool.db.dialect中的枚举
方言名
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.H2Dialect
 
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.MysqlDialect
 
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.OracleDialect
 
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.PostgresqlDialect
 
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.Sqlite3Dialect
 
dialectName() - 类 中的方法cn.hutool.db.dialect.impl.SqlServer2012Dialect
 
Direction - cn.hutool.db.sql中的枚举
排序方式(升序或者降序)
disableWrapper() - 类 中的方法cn.hutool.db.AbstractDb
取消包装器
取消自动添加到字段名、表名上的包装符(例如双引号)
disableWrapper() - 类 中的方法cn.hutool.db.Db
 
disableWrapper() - 类 中的方法cn.hutool.db.Session
 
DRIVER_DERBY - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 Derby
DRIVER_DERBY_EMBEDDED - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 Derby嵌入式
DRIVER_DM7 - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 达梦7
DRIVER_H2 - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 H2
DRIVER_HIVE - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 Hive
DRIVER_HIVE2 - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 Hive2
DRIVER_HSQLDB - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 HSQLDB
DRIVER_MYSQL - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 MySQL
DRIVER_MYSQL_V6 - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 MySQL,在6.X版本中变动驱动类名,且使用SPI机制
DRIVER_ORACLE - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 Oracle
DRIVER_ORACLE_OLD - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 Oracle,旧版使用
DRIVER_POSTGRESQL - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 PostgreSQL
DRIVER_SQLLITE3 - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 SQLLite3
DRIVER_SQLSERVER - 类 中的静态变量cn.hutool.db.dialect.DialectFactory
JDBC 驱动 SQLServer
DriverUtil - cn.hutool.db.dialect中的类
驱动相关工具类,包括自动获取驱动类名
DriverUtil() - 类 的构造器cn.hutool.db.dialect.DriverUtil
 
DruidDSFactory - cn.hutool.db.ds.druid中的类
Druid数据源工厂类
DruidDSFactory() - 类 的构造器cn.hutool.db.ds.druid.DruidDSFactory
构造,使用默认配置文件
DruidDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.druid.DruidDSFactory
构造
ds - 类 中的变量cn.hutool.db.AbstractDb
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.c3p0.C3p0DSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.dbcp.DbcpDSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.druid.DruidDSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.hikari.HikariDSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.jndi.JndiDSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.pooled.PooledDSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.simple.SimpleDSFactory
 
DS_NAME - 类 中的静态变量cn.hutool.db.ds.tomcat.TomcatDSFactory
 
DSFactory - cn.hutool.db.ds中的类
抽象数据源工厂类
通过实现DSFactory.getDataSource(String) 方法实现数据源的获取
如果DataSource 的实现是数据库连接池库,应该在getDataSource调用时创建数据源并缓存
DSFactory(String) - 类 的构造器cn.hutool.db.ds.DSFactory
构造

E

Entity - cn.hutool.db中的类
数据实体对象
数据实体类充当两个角色:
1.
Entity() - 类 的构造器cn.hutool.db.Entity
 
Entity(String) - 类 的构造器cn.hutool.db.Entity
构造
Entity(String, boolean) - 类 的构造器cn.hutool.db.Entity
构造
EntityHandler - cn.hutool.db.handler中的类
Entity对象处理器,只处理第一条数据
EntityHandler() - 类 的构造器cn.hutool.db.handler.EntityHandler
 
EntityListHandler - cn.hutool.db.handler中的类
结果集处理类 ,处理出的结果为Entity列表
EntityListHandler() - 类 的构造器cn.hutool.db.handler.EntityListHandler
构造
EntityListHandler(boolean) - 类 的构造器cn.hutool.db.handler.EntityListHandler
构造
EntitySetHandler - cn.hutool.db.handler中的类
结果集处理类 ,处理出的结果为Entity列表,结果不能重复(按照Entity对象去重)
EntitySetHandler() - 类 的构造器cn.hutool.db.handler.EntitySetHandler
 
equals(Object) - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
 
execute(String, Object...) - 类 中的方法cn.hutool.db.AbstractDb
执行非查询语句
语句包括 插入、更新、删除
execute(Connection, String, Map<String, Object>) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行非查询语句
语句包括 插入、更新、删除
此方法不会关闭Connection
execute(Connection, String, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行非查询语句
语句包括 插入、更新、删除
此方法不会关闭Connection
execute(PreparedStatement, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
可用于执行任何SQL语句,返回一个boolean值,表明执行该SQL语句是否返回了ResultSet。
execute(String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
execute(String, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
execute(String, int[]) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
execute(String, String[]) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
execute() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeBatch(String, Object[]...) - 类 中的方法cn.hutool.db.AbstractDb
批量执行非查询语句
executeBatch(String...) - 类 中的方法cn.hutool.db.AbstractDb
批量执行非查询语句
executeBatch(Connection, String, Object[]...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
批量执行非查询语句
语句包括 插入、更新、删除
此方法不会关闭Connection
executeBatch(Connection, String, Iterable<Object[]>) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
批量执行非查询语句
语句包括 插入、更新、删除
此方法不会关闭Connection
executeBatch(Connection, String...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
批量执行非查询语句
语句包括 插入、更新、删除
此方法不会关闭Connection
executeBatch(Connection, Iterable<String>) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
批量执行非查询语句
语句包括 插入、更新、删除
此方法不会关闭Connection
executeBatch() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeForGeneratedKey(String, Object...) - 类 中的方法cn.hutool.db.AbstractDb
执行非查询语句
语句包括 插入、更新、删除
executeForGeneratedKey(Connection, String, Map<String, Object>) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行非查询语句,返回主键
发查询语句包括 插入、更新、删除
此方法不会关闭Connection
executeForGeneratedKey(Connection, String, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行非查询语句,返回主键
发查询语句包括 插入、更新、删除
此方法不会关闭Connection
executeQuery(String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeQuery() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeUpdate(PreparedStatement, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
用于执行 INSERT、UPDATE 或 DELETE 语句以及 SQL DDL(数据定义语言)语句,例如 CREATE TABLE 和 DROP TABLE。
executeUpdate(String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeUpdate(String, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeUpdate(String, int[]) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeUpdate(String, String[]) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
executeUpdate() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
exist(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
指定条件的数据是否存在

F

fillParams(PreparedStatement, Collection<Object>) - 类 中的静态方法cn.hutool.db.StatementUtil
填充SQL的参数。
fillParams(PreparedStatement, Object...) - 类 中的静态方法cn.hutool.db.StatementUtil
填充SQL的参数。
filter(String...) - 类 中的方法cn.hutool.db.Entity
过滤Map保留指定键值对,如果键不存在跳过
finalize() - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
 
find(Collection<String>, Entity, RsHandler<T>) - 类 中的方法cn.hutool.db.AbstractDb
查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
find(Collection<String>, Entity) - 类 中的方法cn.hutool.db.AbstractDb
查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
find(Query, RsHandler<T>) - 类 中的方法cn.hutool.db.AbstractDb
查询
Query为查询所需数据的一个实体类,此对象中可以定义返回字段、查询条件,查询的表、分页等信息
find(Entity, RsHandler<T>, String...) - 类 中的方法cn.hutool.db.AbstractDb
查询,返回所有字段
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
find(Entity) - 类 中的方法cn.hutool.db.AbstractDb
查询数据列表,返回字段由where参数指定
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
find(Entity, Class<T>) - 类 中的方法cn.hutool.db.AbstractDb
查询数据列表,返回字段由where参数指定
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
find(String, T) - 类 中的方法cn.hutool.db.DaoTemplate
根据某个字段值查询结果
find(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
根据某个字段值查询结果
find(Connection, Query, RsHandler<T>) - 类 中的方法cn.hutool.db.SqlConnRunner
查询
此方法不会关闭Connection
find(Connection, Collection<String>, Entity, RsHandler<T>) - 类 中的方法cn.hutool.db.SqlConnRunner
查询
此方法不会关闭Connection
find(Connection, Entity, RsHandler<T>, String...) - 类 中的方法cn.hutool.db.SqlConnRunner
查询,返回指定字段列表
此方法不会关闭Connection
find(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
查询数据列表,返回字段在where参数中定义
findAll(Entity) - 类 中的方法cn.hutool.db.AbstractDb
查询数据列表,返回所有字段
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
findAll(Entity, Class<T>) - 类 中的方法cn.hutool.db.AbstractDb
查询数据列表,返回所有字段
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
findAll(String) - 类 中的方法cn.hutool.db.AbstractDb
查询数据列表,返回所有字段
findAll() - 类 中的方法cn.hutool.db.DaoTemplate
查询当前表的所有记录
findAll(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
查询数据列表,返回所有字段
findAll(Connection, String) - 类 中的方法cn.hutool.db.SqlConnRunner
查询数据列表,返回所有字段
findBy(String, String, Object) - 类 中的方法cn.hutool.db.AbstractDb
根据某个字段名条件查询数据列表,返回所有字段
findBy(String, Condition...) - 类 中的方法cn.hutool.db.AbstractDb
根据多个条件查询数据列表,返回所有字段
findBy(Connection, String, String, Object) - 类 中的方法cn.hutool.db.SqlConnRunner
根据某个字段名条件查询数据列表,返回所有字段
findBySql(String, Object...) - 类 中的方法cn.hutool.db.DaoTemplate
根据SQL语句查询结果
SQL语句可以是非完整SQL语句,可以只提供查询的条件部分(例如WHERE部分)
此方法会自动补全SELECT * FROM [tableName] 部分,这样就无需关心表名,直接提供条件即可
findIn(Connection, String, String, Object...) - 类 中的方法cn.hutool.db.SqlConnRunner
根据某个字段名条件查询数据列表,返回所有字段
findLike(String, String, String, Condition.LikeType) - 类 中的方法cn.hutool.db.AbstractDb
根据某个字段名条件查询数据列表,返回所有字段
findLike(Connection, String, String, String, Condition.LikeType) - 类 中的方法cn.hutool.db.SqlConnRunner
根据某个字段名条件查询数据列表,返回所有字段
format(String) - 类 中的静态方法cn.hutool.db.sql.SqlFormatter
 
formatSql(String) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
格式化SQL
free(PooledConnection) - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
释放连接,连接会被返回给连接池
from(String...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
添加 from语句
fromString(String) - 枚举 中的静态方法cn.hutool.db.sql.Direction
根据字符串值返回对应Direction

G

get(String, String, T) - 类 中的方法cn.hutool.db.AbstractDb
根据某个字段(最好是唯一字段)查询单个记录
当有多条返回时,只显示查询到的第一条
get(Entity) - 类 中的方法cn.hutool.db.AbstractDb
根据条件实体查询单个记录,当有多条返回时,只显示查询到的第一条
get(T) - 类 中的方法cn.hutool.db.DaoTemplate
根据主键获取单个记录
get(String, T) - 类 中的方法cn.hutool.db.DaoTemplate
根据某个字段(最好是唯一字段)查询单个记录
当有多条返回时,只显示查询到的第一条
get(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
根据条件实体查询单个记录,当有多条返回时,只显示查询到的第一条
get() - 类 中的静态方法cn.hutool.db.ds.DSFactory
获得数据源
使用默认配置文件的无分组配置
get(String) - 类 中的静态方法cn.hutool.db.ds.DSFactory
获得数据源
get() - 类 中的静态方法cn.hutool.db.ds.GlobalDSFactory
获取默认的数据源工厂,读取默认数据库配置文件
此处使用懒加载模式,在第一次调用此方法时才创建默认数据源工厂
如果想自定义全局的数据源工厂,请在第一次调用此方法前调用GlobalDSFactory.set(DSFactory) 方法自行定义
get(DataSource) - 枚举 中的方法cn.hutool.db.ThreadLocalConnection
获取数据源对应的数据库连接
get(DataSource) - 类 中的方法cn.hutool.db.ThreadLocalConnection.GroupedConnection
获取连接,如果获取的连接为空或者已被关闭,重新创建连接
getAutoCommit() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getBlob(String) - 类 中的方法cn.hutool.db.Entity
获得Blob类型结果
getCatalog() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getCataLog(Connection) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获取catalog,获取失败返回null
getClientInfo(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getClientInfo() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getClob(String) - 类 中的方法cn.hutool.db.Entity
获得Clob类型结果
getCollection(String, String) - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
获得MongoDB中指定集合对象
getColumn(String) - 类 中的方法cn.hutool.db.meta.Table
获取某列信息
getColumnNames(ResultSet) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得结果集的所有列名
getColumnNames(DataSource, String) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得表的所有列名
getColumns() - 类 中的方法cn.hutool.db.meta.Table
获取所有字段元信息
getComment() - 类 中的方法cn.hutool.db.meta.Column
获取注释
getComment() - 类 中的方法cn.hutool.db.meta.Table
获取注释
getConfig() - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
 
getConnection() - 类 中的方法cn.hutool.db.AbstractDb
获得链接。
getConnection() - 类 中的方法cn.hutool.db.Db
 
getConnection() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
getConnection(String, String) - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
getConnection() - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
从数据库连接池中获取数据库连接对象
getConnection(String, String) - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
 
getConnection(long) - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
获取连接对象
getConnection() - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
getConnection(String, String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
getConnection() - 类 中的方法cn.hutool.db.Session
 
getConnection() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getConnection() - 类 中的方法cn.hutool.db.SqlRunner
已过时。
 
getCurrentDSFactory(Setting) - 类 中的静态方法cn.hutool.db.ds.DSFactory
已过时。
此方法容易引起歧义,应使用DSFactory.create(Setting) 方法代替之
getDataSource(String) - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
 
getDataSource() - 类 中的方法cn.hutool.db.ds.DSFactory
获得默认数据源
getDataSource(String) - 类 中的方法cn.hutool.db.ds.DSFactory
获得分组对应数据源
getDataSource(String) - 类 中的静态方法cn.hutool.db.ds.pooled.PooledDataSource
获得一个数据源
getDataSource() - 类 中的静态方法cn.hutool.db.ds.pooled.PooledDataSource
获得一个数据源,使用空分组
getDataSource(String) - 类 中的静态方法cn.hutool.db.ds.simple.SimpleDataSource
获得一个数据源
getDataSource() - 类 中的静态方法cn.hutool.db.ds.simple.SimpleDataSource
获得一个数据源,无分组
getDate(String) - 类 中的方法cn.hutool.db.Entity
 
getDb(String) - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
获得DB
getDbConfig(String) - 类 中的方法cn.hutool.db.ds.pooled.DbSetting
获得数据库连接信息
getDialect(DataSource) - 类 中的静态方法cn.hutool.db.dialect.DialectFactory
获取共享方言
getDialect() - 类 中的方法cn.hutool.db.SqlConnRunner
 
getDirection() - 类 中的方法cn.hutool.db.sql.Order
 
getDriver() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
获取驱动名
getDriver() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getDriver() - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
getDs() - 类 中的静态方法cn.hutool.db.DbUtil
获得默认数据源
getDs(String) - 类 中的静态方法cn.hutool.db.DbUtil
获取指定分组的数据源
getDS(String, int) - 类 中的静态方法cn.hutool.db.nosql.mongo.MongoFactory
获取MongoDB数据源
getDS(String...) - 类 中的静态方法cn.hutool.db.nosql.mongo.MongoFactory
获取MongoDB数据源
多个分组名对应的连接组成集群
getDS(Collection<String>) - 类 中的静态方法cn.hutool.db.nosql.mongo.MongoFactory
获取MongoDB数据源
getDS(Setting, String...) - 类 中的静态方法cn.hutool.db.nosql.mongo.MongoFactory
获取MongoDB数据源
getDS(Setting, Collection<String>) - 类 中的静态方法cn.hutool.db.nosql.mongo.MongoFactory
获取MongoDB数据源
getEndPosition() - 类 中的方法cn.hutool.db.Page
 
getFetchDirection() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getFetchSize() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getField() - 类 中的方法cn.hutool.db.sql.Condition
 
getField() - 类 中的方法cn.hutool.db.sql.Order
 
getFieldArray() - 类 中的方法cn.hutool.db.sql.SqlBuilder
获得插入或更新的数据库字段列表
getFieldNames() - 类 中的方法cn.hutool.db.Entity
 
getFields() - 类 中的方法cn.hutool.db.sql.Query
获得查询的字段名列表
getFields() - 类 中的方法cn.hutool.db.sql.SqlBuilder
获得插入或更新的数据库字段列表
getFirstTableName() - 类 中的方法cn.hutool.db.sql.Query
获得第一个表名
getGeneratedKeyOfLong(PreparedStatement) - 类 中的静态方法cn.hutool.db.StatementUtil
获得自增键的值
此方法对于Oracle无效
getGeneratedKeys() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getGeneratedKeys(PreparedStatement) - 类 中的静态方法cn.hutool.db.StatementUtil
获得所有主键
getHoldability() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getInitialSize() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getJedis() - 类 中的方法cn.hutool.db.nosql.redis.RedisDS
从资源池中获取Jedis
getJndiDs(String) - 类 中的静态方法cn.hutool.db.DbUtil
获得JNDI数据源
getJndiDsWithLog(String) - 类 中的静态方法cn.hutool.db.DbUtil
获得JNDI数据源
getLevel() - 枚举 中的方法cn.hutool.db.transaction.TransactionLevel
获取数据库事务级别int值
getLoginTimeout() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
getLoginTimeout() - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
 
getLogWriter() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
getLogWriter() - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
 
getMaxActive() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getMaxFieldSize() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getMaxRows() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getMaxWait() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getMetaData() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getMetaData() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getMinIdle() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getMongo() - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
 
getMoreResults() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getMoreResults(int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getName() - 类 中的方法cn.hutool.db.meta.Column
获取列名
getNetworkTimeout() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getNumPerPage() - 类 中的方法cn.hutool.db.Page
已过时。
使用 Page.getPageSize() 代替
getNumPerPage() - 类 中的方法cn.hutool.db.PageResult
已过时。
getOperator() - 类 中的方法cn.hutool.db.sql.Condition
获得运算符
大于号,小于号,等于号 等
getOrders() - 类 中的方法cn.hutool.db.Page
 
getPage() - 类 中的方法cn.hutool.db.PageResult
 
getPage() - 类 中的方法cn.hutool.db.sql.Query
获得分页对象
getPageNumber() - 类 中的方法cn.hutool.db.Page
 
getPageSize() - 类 中的方法cn.hutool.db.Page
 
getPageSize() - 类 中的方法cn.hutool.db.PageResult
 
getParameterMetaData() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getParamList() - 类 中的方法cn.hutool.db.sql.NamedSql
获取参数列表,按照占位符顺序
getParams() - 类 中的方法cn.hutool.db.sql.NamedSql
获取参数列表,按照占位符顺序
getParamValueArray() - 类 中的方法cn.hutool.db.sql.SqlBuilder
获得占位符对应的值列表
getParamValues() - 类 中的方法cn.hutool.db.sql.SqlBuilder
获得占位符对应的值列表
getParentLogger() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
getParentLogger() - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
Support from JDK7
getPass() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getPass() - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
getPkNames() - 类 中的方法cn.hutool.db.meta.Table
获取主键列表
getPreWrapQuote() - 类 中的方法cn.hutool.db.sql.Wrapper
 
getQueryTimeout() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getRaw() - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
获取原始的数据源
getRaw() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getResultSet() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getResultSetConcurrency() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getResultSetHoldability() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getResultSetType() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getRowId() - 类 中的方法cn.hutool.db.Entity
获得rowid
getRowId(String) - 类 中的方法cn.hutool.db.Entity
获得rowid
getRunner() - 类 中的方法cn.hutool.db.AbstractDb
getRunner() - 类 中的方法cn.hutool.db.Session
getSchema() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getSchema(Connection) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获取schema,获取失败返回null
getSecondValue() - 类 中的方法cn.hutool.db.sql.Condition
获得between 类型中第二个值
getSetting() - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
获取配置,用于自定义添加配置项
getSize() - 类 中的方法cn.hutool.db.meta.Column
获取大小或数据长度
getSql() - 类 中的方法cn.hutool.db.sql.NamedSql
获取SQL
getStartEnd() - 类 中的方法cn.hutool.db.Page
开始位置和结束位置
例如:
页码:1,每页10 =》 [0, 10]
页码:2,每页10 =》 [10, 20]
。。。
getStartPosition() - 类 中的方法cn.hutool.db.Page
 
getStr(String) - 类 中的方法cn.hutool.db.Entity
 
getStr(String, Charset) - 类 中的方法cn.hutool.db.Entity
获得字符串值
支持Clob、Blob、RowId
getStr(String) - 类 中的方法cn.hutool.db.nosql.redis.RedisDS
从Redis中获取值
getSufWrapQuote() - 类 中的方法cn.hutool.db.sql.Wrapper
 
getTableMeta(DataSource, String) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得表的元信息
getTableName() - 类 中的方法cn.hutool.db.Entity
 
getTableName() - 类 中的方法cn.hutool.db.meta.Column
获取表名
getTableName() - 类 中的方法cn.hutool.db.meta.Table
获取表名
getTableNames() - 类 中的方法cn.hutool.db.sql.Query
获得表名数组
getTables(DataSource) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得所有表名
getTables(DataSource, TableType...) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得所有表名
getTables(DataSource, String, TableType...) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得所有表名
getTables(DataSource, String, String, TableType...) - 类 中的静态方法cn.hutool.db.meta.MetaUtil
获得所有表名
getTime(String) - 类 中的方法cn.hutool.db.Entity
 
getTimestamp(String) - 类 中的方法cn.hutool.db.Entity
 
getTotal() - 类 中的方法cn.hutool.db.PageResult
 
getTotalPage() - 类 中的方法cn.hutool.db.PageResult
 
getTransactionIsolation() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getType() - 类 中的方法cn.hutool.db.meta.Column
获取类型,对应Types中的类型
getTypeEnum() - 类 中的方法cn.hutool.db.meta.Column
获取字段类型的枚举
getTypeMap() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getTypeName() - 类 中的方法cn.hutool.db.meta.Column
获取类型名称
getUpdateCount() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getUrl() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getUrl() - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
getUser() - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
getUser() - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
getValue() - 类 中的方法cn.hutool.db.sql.Condition
获得值
getWarnings() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
getWarnings() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
getWhere() - 类 中的方法cn.hutool.db.sql.Query
获得条件语句
getWrapper() - 接口 中的方法cn.hutool.db.dialect.Dialect
 
getWrapper() - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
GlobalDSFactory - cn.hutool.db.ds中的类
全局的数据源工厂
一般情况下,一个应用默认只使用一种数据库连接池,因此维护一个全局的数据源工厂类减少判断连接池类型造成的性能浪费
GlobalDSFactory() - 类 的构造器cn.hutool.db.ds.GlobalDSFactory
 
groupBy(String...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
分组

H

H2Dialect - cn.hutool.db.dialect.impl中的类
H2数据库方言
H2Dialect() - 类 的构造器cn.hutool.db.dialect.impl.H2Dialect
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.BeanHandler
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.BeanListHandler
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.EntityHandler
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.EntityListHandler
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.EntitySetHandler
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.NumberHandler
 
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.PageResultHandler
 
handle(ResultSet) - 接口 中的方法cn.hutool.db.handler.RsHandler
处理结果集
结果集处理后不需要关闭
handle(ResultSet) - 类 中的方法cn.hutool.db.handler.StringHandler
 
HandleHelper - cn.hutool.db.handler中的类
数据结果集处理辅助类
HandleHelper() - 类 的构造器cn.hutool.db.handler.HandleHelper
 
handleRow(int, ResultSetMetaData, ResultSet, T) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理单条数据
handleRow(int, ResultSetMetaData, ResultSet, Class<T>) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理单条数据
handleRow(int, ResultSetMetaData, ResultSet) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理单条数据
handleRow(int, ResultSetMetaData, ResultSet, boolean) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理单条数据
handleRow(T, int, ResultSetMetaData, ResultSet, boolean) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理单条数据
handleRow(ResultSet) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理单条数据
handleRs(ResultSet, T) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理多条数据
handleRs(ResultSet, T, boolean) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理多条数据
handleRsToBeanList(ResultSet, T, Class<E>) - 类 中的静态方法cn.hutool.db.handler.HandleHelper
处理多条数据并返回一个Bean列表
hashCode() - 类 中的方法cn.hutool.db.ds.AbstractDSFactory
 
having(LogicalOperator, Condition...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
添加Having语句
having(String) - 类 中的方法cn.hutool.db.sql.SqlBuilder
添加Having语句
HikariDSFactory - cn.hutool.db.ds.hikari中的类
HikariCP数据源工厂类
HikariDSFactory() - 类 的构造器cn.hutool.db.ds.hikari.HikariDSFactory
 
HikariDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.hikari.HikariDSFactory
 

I

identifyDriver(String) - 类 中的静态方法cn.hutool.db.dialect.DialectFactory
通过JDBC URL等信息识别JDBC驱动名
identifyDriver(String) - 类 中的静态方法cn.hutool.db.dialect.DriverUtil
通过JDBC URL等信息识别JDBC驱动名
identifyDriver(DataSource) - 类 中的静态方法cn.hutool.db.dialect.DriverUtil
识别JDBC驱动名
identifyDriver(Connection) - 类 中的静态方法cn.hutool.db.dialect.DriverUtil
识别JDBC驱动名
in(String, T...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
多值选择
init(String, String, String) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
初始化
init(String, String, String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
初始化
init(String, String, String, String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
初始化
init(String, ResultSet) - 类 中的方法cn.hutool.db.meta.Column
初始化
init() - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
初始化,当给定分组数大于一个时使用
init(String) - 类 中的方法cn.hutool.db.nosql.redis.RedisDS
初始化Jedis客户端
init(boolean, boolean, boolean, Level) - 枚举 中的方法cn.hutool.db.sql.SqlLog
设置全局配置:是否通过debug日志显示SQL
initCloud() - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
初始化集群
集群的其它客户端设定参数使用全局设定
集群中每一个实例成员用一个group表示,例如: user = test1 pass = 123456 database = test [db0] host = 192.168.1.1:27117 [db1] host = 192.168.1.1:27118 [db2] host = 192.168.1.1:27119
initSingle() - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
初始化
设定文件中的host和端口有三种形式: host = host:port host = host port = port host = host
insert(Entity) - 类 中的方法cn.hutool.db.AbstractDb
插入数据
insert(Collection<Entity>) - 类 中的方法cn.hutool.db.AbstractDb
批量插入数据
需要注意的是,批量插入每一条数据结构必须一致。
insert(Entity) - 类 中的方法cn.hutool.db.sql.SqlBuilder
插入,使用默认的ANSI方言
insert(Entity, DialectName) - 类 中的方法cn.hutool.db.sql.SqlBuilder
插入
插入会忽略空的字段名及其对应值,但是对于有字段名对应值为null的情况不忽略
insert(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
插入数据
此方法不会关闭Connection
insert(Connection, Collection<Entity>) - 类 中的方法cn.hutool.db.SqlConnRunner
批量插入数据
需要注意的是,批量插入每一条数据结构必须一致。
insert(Connection, Entity...) - 类 中的方法cn.hutool.db.SqlConnRunner
批量插入数据
批量插入必须严格保持Entity的结构一致,不一致会导致插入数据出现不可预知的结果
此方法不会关闭Connection
insertForGeneratedKey(Entity) - 类 中的方法cn.hutool.db.AbstractDb
插入数据
insertForGeneratedKey(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
插入数据
此方法不会关闭Connection
insertForGeneratedKeys(Entity) - 类 中的方法cn.hutool.db.AbstractDb
插入数据
insertForGeneratedKeys(Connection, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
插入数据
此方法不会关闭Connection
insertOrUpdate(Entity, String...) - 类 中的方法cn.hutool.db.AbstractDb
插入或更新数据
根据给定的字段名查询数据,如果存在则更新这些数据,否则执行插入
insertOrUpdate(Connection, Entity, String...) - 类 中的方法cn.hutool.db.SqlConnRunner
插入数据
此方法不会关闭Connection
insertPreFragment(Object) - 类 中的方法cn.hutool.db.sql.SqlBuilder
在SQL的开头补充SQL片段
isClosed() - 类 中的方法cn.hutool.db.ds.pooled.PooledConnection
连接是否关闭,关闭条件:
1、被归还到池中 2、实际连接已关闭
isClosed() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
isCloseOnCompletion() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
isFirst() - 类 中的方法cn.hutool.db.PageResult
 
isLast() - 类 中的方法cn.hutool.db.PageResult
 
isNullable() - 类 中的方法cn.hutool.db.meta.Column
是否为可空
isOperatorBetween() - 类 中的方法cn.hutool.db.sql.Condition
是否 between x and y 类型
isOperatorIn() - 类 中的方法cn.hutool.db.sql.Condition
是否IN条件
isOperatorIs() - 类 中的方法cn.hutool.db.sql.Condition
是否IS条件
isPlaceHolder() - 类 中的方法cn.hutool.db.sql.Condition
是否使用条件占位符
isPoolable() - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
isReadOnly() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
isSame(String) - 枚举 中的方法cn.hutool.db.sql.LogicalOperator
给定字符串逻辑运算符是否与当前逻辑运算符一致,不区分大小写,自动去除两边空白符
isSupportTransaction - 类 中的变量cn.hutool.db.AbstractDb
是否支持事务
isValid(int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
isWrapperFor(Class<?>) - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
isWrapperFor(Class<?>) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
isWrapperFor(Class<?>) - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
 
isWrapperFor(Class<?>) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 

J

JdbcType - cn.hutool.db.meta中的枚举
 
JndiDSFactory - cn.hutool.db.ds.jndi中的类
JNDI数据源工厂类
Setting配置样例:
---------------------
[group]
jndi = jdbc/TestDB
---------------------
JndiDSFactory() - 类 的构造器cn.hutool.db.ds.jndi.JndiDSFactory
 
JndiDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.jndi.JndiDSFactory
 
join(String, SqlBuilder.Join) - 类 中的方法cn.hutool.db.sql.SqlBuilder
多表关联

K

KEY_ALIAS_DRIVER - 类 中的静态变量cn.hutool.db.ds.DSFactory
别名字段名:驱动名
KEY_ALIAS_PASSWORD - 类 中的静态变量cn.hutool.db.ds.DSFactory
别名字段名:密码
KEY_ALIAS_URL - 类 中的静态变量cn.hutool.db.ds.DSFactory
别名字段名:URL
KEY_ALIAS_USER - 类 中的静态变量cn.hutool.db.ds.DSFactory
别名字段名:用户名

L

load() - 类 中的方法cn.hutool.db.ActiveEntity
根据Entity中现有字段条件从数据库中加载一个Entity对象
log(String, Object) - 枚举 中的方法cn.hutool.db.sql.SqlLog
打印SQL日志
LogicalOperator - cn.hutool.db.sql中的枚举
逻辑运算符

M

MetaUtil - cn.hutool.db.meta中的类
数据库元数据信息工具类
MetaUtil() - 类 的构造器cn.hutool.db.meta.MetaUtil
 
MONGO_CONFIG_PATH - 类 中的静态变量cn.hutool.db.nosql.mongo.MongoDS
默认配置文件
MongoDS - cn.hutool.db.nosql.mongo中的类
MongoDB工具类
MongoDS(String, int) - 类 的构造器cn.hutool.db.nosql.mongo.MongoDS
构造MongoDB数据源
调用者必须持有MongoDS实例,否则会被垃圾回收导致写入失败!
MongoDS(Setting, String, int) - 类 的构造器cn.hutool.db.nosql.mongo.MongoDS
构造MongoDB数据源
调用者必须持有MongoDS实例,否则会被垃圾回收导致写入失败!
MongoDS(String...) - 类 的构造器cn.hutool.db.nosql.mongo.MongoDS
构造MongoDB数据源
当提供多个数据源时,这些数据源将为一个副本集或者多个mongos
调用者必须持有MongoDS实例,否则会被垃圾回收导致写入失败!
MongoDS(Setting, String...) - 类 的构造器cn.hutool.db.nosql.mongo.MongoDS
构造MongoDB数据源
当提供多个数据源时,这些数据源将为一个副本集或者mongos
调用者必须持有MongoDS实例,否则会被垃圾回收导致写入失败!
MongoFactory - cn.hutool.db.nosql.mongo中的类
MongoDB工厂类,用于创建
MongoFactory() - 类 的构造器cn.hutool.db.nosql.mongo.MongoFactory
 
MysqlDialect - cn.hutool.db.dialect.impl中的类
MySQL方言
MysqlDialect() - 类 的构造器cn.hutool.db.dialect.impl.MysqlDialect
 

N

NamedSql - cn.hutool.db.sql中的类
使用命名占位符的SQL,例如:select * from table where field1=:name1
支持的占位符格式为: 1、:name 2、?
NamedSql(String, Map<String, Object>) - 类 的构造器cn.hutool.db.sql.NamedSql
构造
nativeSQL(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
newConnection() - 类 中的方法cn.hutool.db.ds.pooled.PooledDataSource
创建新连接
newDialect(String) - 类 中的静态方法cn.hutool.db.dialect.DialectFactory
根据驱动名创建方言
驱动名是不分区大小写完全匹配的
newDialect(DataSource) - 类 中的静态方法cn.hutool.db.dialect.DialectFactory
创建方言
newDialect(Connection) - 类 中的静态方法cn.hutool.db.dialect.DialectFactory
创建方言
newSession() - 类 中的静态方法cn.hutool.db.DbUtil
新建数据库会话,使用默认数据源
newSession(DataSource) - 类 中的静态方法cn.hutool.db.DbUtil
新建数据库会话
newSqlConnRunner(Dialect) - 类 中的静态方法cn.hutool.db.DbUtil
实例化一个新的SQL运行对象
newSqlConnRunner(DataSource) - 类 中的静态方法cn.hutool.db.DbUtil
实例化一个新的SQL运行对象
newSqlConnRunner(Connection) - 类 中的静态方法cn.hutool.db.DbUtil
实例化一个新的SQL运行对象
newSqlRunner() - 类 中的静态方法cn.hutool.db.DbUtil
已过时。
请使用 DbUtil.use()
newSqlRunner(DataSource) - 类 中的静态方法cn.hutool.db.DbUtil
已过时。
newSqlRunner(DataSource, Dialect) - 类 中的静态方法cn.hutool.db.DbUtil
已过时。
NumberHandler - cn.hutool.db.handler中的类
处理为数字结果,当查询结果为单个数字时使用此处理器(例如select count(1))
NumberHandler() - 类 的构造器cn.hutool.db.handler.NumberHandler
 

O

on(LogicalOperator, Condition...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
配合JOIN的 ON语句,多表关联的条件语句
只支持单一的逻辑运算符(例如多个条件之间)
on(String) - 类 中的方法cn.hutool.db.sql.SqlBuilder
配合JOIN的 ON语句,多表关联的条件语句
只支持单一的逻辑运算符(例如多个条件之间)
open() - 类 中的方法cn.hutool.db.ds.pooled.PooledConnection
打开连接
OracleDialect - cn.hutool.db.dialect.impl中的类
Oracle 方言
OracleDialect() - 类 的构造器cn.hutool.db.dialect.impl.OracleDialect
 
Order - cn.hutool.db.sql中的类
SQL排序对象
Order() - 类 的构造器cn.hutool.db.sql.Order
 
Order(String) - 类 的构造器cn.hutool.db.sql.Order
构造
Order(String, Direction) - 类 的构造器cn.hutool.db.sql.Order
构造
orderBy(Order...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
排序

P

page(Collection<String>, Entity, int, int, RsHandler<T>) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Entity, int, int, RsHandler<T>) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Entity, Page, RsHandler<T>) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Collection<String>, Entity, Page, RsHandler<T>) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Collection<String>, Entity, int, int) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Collection<String>, Entity, Page) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Entity, int, int) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Entity, Page) - 类 中的方法cn.hutool.db.AbstractDb
分页查询
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
page(Entity, Page, String...) - 类 中的方法cn.hutool.db.DaoTemplate
分页
page(Entity, Page) - 类 中的方法cn.hutool.db.DaoTemplate
分页
Page - cn.hutool.db中的类
分页对象
Page() - 类 的构造器cn.hutool.db.Page
构造,默认第0页,每页20
Page(int, int) - 类 的构造器cn.hutool.db.Page
构造
Page(int, int, Order) - 类 的构造器cn.hutool.db.Page
构造
page(Connection, Collection<String>, Entity, int, int, RsHandler<T>) - 类 中的方法cn.hutool.db.SqlConnRunner
分页查询
此方法不会关闭Connection
page(Connection, Collection<String>, Entity, Page, RsHandler<T>) - 类 中的方法cn.hutool.db.SqlConnRunner
分页查询
此方法不会关闭Connection
page(Connection, Collection<String>, Entity, int, int) - 类 中的方法cn.hutool.db.SqlConnRunner
分页查询
此方法不会关闭Connection
page(Connection, Collection<String>, Entity, Page) - 类 中的方法cn.hutool.db.SqlConnRunner
分页查询
此方法不会关闭Connection
page(Connection, Entity, Page) - 类 中的方法cn.hutool.db.SqlConnRunner
分页全字段查询
此方法不会关闭Connection
pageForEntityList(Entity, int, int) - 类 中的方法cn.hutool.db.AbstractDb
分页查询,结果为Entity列表,不计算总数
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
pageForEntityList(Entity, Page) - 类 中的方法cn.hutool.db.AbstractDb
分页查询,结果为Entity列表,不计算总数
查询条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
PageResult<T> - cn.hutool.db中的类
分页数据结果集
PageResult(int, int) - 类 的构造器cn.hutool.db.PageResult
构造
PageResult(int, int, int) - 类 的构造器cn.hutool.db.PageResult
构造
PageResultHandler - cn.hutool.db.handler中的类
分页结果集处理类 ,处理出的结果为PageResult
PageResultHandler(PageResult<Entity>) - 类 的构造器cn.hutool.db.handler.PageResultHandler
构造
结果集根据给定的分页对象查询数据库,填充结果
parse(T) - 类 中的静态方法cn.hutool.db.ActiveEntity
将PO对象转为Entity
parse(T, boolean, boolean) - 类 中的静态方法cn.hutool.db.ActiveEntity
将PO对象转为ActiveEntity
parse(T) - 类 中的静态方法cn.hutool.db.Entity
将PO对象转为Entity
parse(T, boolean, boolean) - 类 中的静态方法cn.hutool.db.Entity
将PO对象转为Entity
parse(String, Object) - 类 中的静态方法cn.hutool.db.sql.Condition
解析为Condition
parseBean(T) - 类 中的方法cn.hutool.db.ActiveEntity
 
parseBean(T, boolean, boolean) - 类 中的方法cn.hutool.db.ActiveEntity
 
parseBean(T) - 类 中的方法cn.hutool.db.Entity
将值对象转换为Entity
类名会被当作表名,小写第一个字母
parseBean(T, boolean, boolean) - 类 中的方法cn.hutool.db.Entity
将值对象转换为Entity
类名会被当作表名,小写第一个字母
parseWithUnderlineCase(T) - 类 中的静态方法cn.hutool.db.ActiveEntity
将PO对象转为ActiveEntity,并采用下划线法转换字段
parseWithUnderlineCase(T) - 类 中的静态方法cn.hutool.db.Entity
将PO对象转为Entity,并采用下划线法转换字段
PooledConnection - cn.hutool.db.ds.pooled中的类
池化
PooledConnection(PooledDataSource) - 类 的构造器cn.hutool.db.ds.pooled.PooledConnection
 
PooledConnection(PooledDataSource, Connection) - 类 的构造器cn.hutool.db.ds.pooled.PooledConnection
 
PooledDataSource - cn.hutool.db.ds.pooled中的类
池化数据源
PooledDataSource() - 类 的构造器cn.hutool.db.ds.pooled.PooledDataSource
构造,读取默认的配置文件和默认分组
PooledDataSource(String) - 类 的构造器cn.hutool.db.ds.pooled.PooledDataSource
构造,读取默认的配置文件
PooledDataSource(DbSetting, String) - 类 的构造器cn.hutool.db.ds.pooled.PooledDataSource
构造
PooledDataSource(DbConfig) - 类 的构造器cn.hutool.db.ds.pooled.PooledDataSource
构造
PooledDSFactory - cn.hutool.db.ds.pooled中的类
Hutool自身实现的池化数据源工厂类
PooledDSFactory() - 类 的构造器cn.hutool.db.ds.pooled.PooledDSFactory
 
PooledDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.pooled.PooledDSFactory
 
PostgresqlDialect - cn.hutool.db.dialect.impl中的类
Postgree方言
PostgresqlDialect() - 类 的构造器cn.hutool.db.dialect.impl.PostgresqlDialect
 
prepareCall(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareCall(String, int, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareCall(String, int, int, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareCall(Connection, String, Object...) - 类 中的静态方法cn.hutool.db.StatementUtil
prepareStatement(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareStatement(String, int, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareStatement(String, int, int, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareStatement(String, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareStatement(String, int[]) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareStatement(String, String[]) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
prepareStatement(Connection, SqlBuilder) - 类 中的静态方法cn.hutool.db.StatementUtil
prepareStatement(Connection, String, Collection<Object>) - 类 中的静态方法cn.hutool.db.StatementUtil
prepareStatement(Connection, String, Object...) - 类 中的静态方法cn.hutool.db.StatementUtil
prepareStatementForBatch(Connection, String, Object[]...) - 类 中的静态方法cn.hutool.db.StatementUtil
创建批量操作的PreparedStatement
prepareStatementForBatch(Connection, String, Iterable<Object[]>) - 类 中的静态方法cn.hutool.db.StatementUtil
创建批量操作的PreparedStatement
primaryKeyField - 类 中的变量cn.hutool.db.DaoTemplate
本表的主键字段,请在子类中覆盖或构造方法中指定,默认为id
psForCount(Connection, Query) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于查询行数的PreparedStatement
psForCount(Connection, Query) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
psForDelete(Connection, Query) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于删除的PreparedStatement
psForDelete(Connection, Query) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
psForFind(Connection, Query) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于获取多条记录的PreparedStatement
psForFind(Connection, Query) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
psForInsert(Connection, Entity) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于插入的PreparedStatement
psForInsert(Connection, Entity) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
psForInsertBatch(Connection, Entity...) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于批量插入的PreparedStatement
psForInsertBatch(Connection, Entity...) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
psForPage(Connection, Query) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于分页查询的PreparedStatement
psForPage(Connection, Query) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
psForUpdate(Connection, Entity, Query) - 接口 中的方法cn.hutool.db.dialect.Dialect
构建用于更新的PreparedStatement
psForUpdate(Connection, Entity, Query) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 

Q

query(String, Object...) - 类 中的方法cn.hutool.db.AbstractDb
查询
query(String, Class<T>, Object...) - 类 中的方法cn.hutool.db.AbstractDb
查询
query(String, RsHandler<T>, Object...) - 类 中的方法cn.hutool.db.AbstractDb
查询
Query - cn.hutool.db.sql中的类
查询对象,用于传递查询所需的字段值
查询对象根据表名(可以多个),多个条件 Condition 构建查询对象完成查询。
Query(String...) - 类 的构造器cn.hutool.db.sql.Query
构造
Query(Condition[], String...) - 类 的构造器cn.hutool.db.sql.Query
构造
Query(Condition[], Page, String...) - 类 的构造器cn.hutool.db.sql.Query
构造
Query(Collection<String>, String[], Condition[], Page) - 类 的构造器cn.hutool.db.sql.Query
构造
query(Query) - 类 中的方法cn.hutool.db.sql.SqlBuilder
构建查询SQL
query(Connection, String, RsHandler<T>, Map<String, Object>) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行查询语句
此方法不会关闭Connection
query(Connection, String, RsHandler<T>, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行查询语句
此方法不会关闭Connection
query(PreparedStatement, RsHandler<T>, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行查询语句
此方法不会关闭PreparedStatement
queryAndClosePs(PreparedStatement, RsHandler<T>, Object...) - 类 中的静态方法cn.hutool.db.sql.SqlExecutor
执行查询语句并关闭PreparedStatement
queryNumber(String, Object...) - 类 中的方法cn.hutool.db.AbstractDb
查询单条单个字段记录,并将其转换为Number
queryOne(String, Object...) - 类 中的方法cn.hutool.db.AbstractDb
查询单条记录
queryString(String, Object...) - 类 中的方法cn.hutool.db.AbstractDb
查询单条单个字段记录,并将其转换为String
quietRollback() - 类 中的方法cn.hutool.db.Session
静默回滚事务
回滚事务
quietRollback(Savepoint) - 类 中的方法cn.hutool.db.Session
静默回滚到某个保存点,保存点的设置请使用setSavepoint方法

R

raw - 类 中的变量cn.hutool.db.ds.pooled.ConnectionWraper
 
REDIS_CONFIG_PATH - 类 中的静态变量cn.hutool.db.nosql.redis.RedisDS
默认配置文件
RedisDS - cn.hutool.db.nosql.redis中的类
Jedis数据源
RedisDS() - 类 的构造器cn.hutool.db.nosql.redis.RedisDS
构造,使用默认配置文件,默认分组
RedisDS(String) - 类 的构造器cn.hutool.db.nosql.redis.RedisDS
构造,使用默认配置文件
RedisDS(Setting, String) - 类 的构造器cn.hutool.db.nosql.redis.RedisDS
构造
release() - 类 中的方法cn.hutool.db.ds.pooled.PooledConnection
释放连接
releaseSavepoint(Savepoint) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
rollback() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
rollback(Savepoint) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
rollback() - 类 中的方法cn.hutool.db.Session
回滚事务
rollback(Savepoint) - 类 中的方法cn.hutool.db.Session
回滚到某个保存点,保存点的设置请使用setSavepoint方法
rowIdToString(RowId) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
将RowId转为字符串
RsHandler<T> - cn.hutool.db.handler中的接口
结果集处理接口
此接口用于实现ResultSet 转换或映射为用户指定的pojo对象 默认实现有:
runner - 类 中的变量cn.hutool.db.AbstractDb
 

S

select(boolean, String...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
查询
select(boolean, Collection<String>) - 类 中的方法cn.hutool.db.sql.SqlBuilder
查询
select(String...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
查询(非Distinct)
select(Collection<String>) - 类 中的方法cn.hutool.db.sql.SqlBuilder
查询(非Distinct)
Session - cn.hutool.db中的类
数据库SQL执行会话
会话通过共用Connection而可以实现JDBC事务
一个会话只维护一个连接,推荐在执行完后关闭Session,避免重用
本对象并不是线程安全的,多个线程共用一个Session将会导致不可预知的问题
Session(DataSource) - 类 的构造器cn.hutool.db.Session
构造,从DataSource中识别方言
Session(DataSource, String) - 类 的构造器cn.hutool.db.Session
构造
Session(DataSource, Dialect) - 类 的构造器cn.hutool.db.Session
构造
set(String, Object) - 类 中的方法cn.hutool.db.ActiveEntity
 
set(DSFactory) - 类 中的静态方法cn.hutool.db.ds.GlobalDSFactory
设置全局的数据源工厂
在项目中存在多个连接池库的情况下,我们希望使用低优先级的库时使用此方法自定义之
重新定义全局的数据源工厂此方法可在以下两种情况下调用: 1.
set(String, Object) - 类 中的方法cn.hutool.db.Entity
 
setArray(int, Array) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setAsciiStream(int, InputStream, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setAsciiStream(int, InputStream, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setAsciiStream(int, InputStream) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setAutoCommit(boolean) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setBigDecimal(int, BigDecimal) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBinaryStream(int, InputStream, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBinaryStream(int, InputStream, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBinaryStream(int, InputStream) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBlob(int, Blob) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBlob(int, InputStream, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBlob(int, InputStream) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBoolean(int, boolean) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setByte(int, byte) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setBytes(int, byte[]) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setCatalog(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setCharacterStream(int, Reader, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setCharacterStream(int, Reader, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setCharacterStream(int, Reader) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setClientInfo(String, String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setClientInfo(Properties) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setClob(int, Clob) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setClob(int, Reader, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setClob(int, Reader) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setColumn(Column) - 类 中的方法cn.hutool.db.meta.Table
设置列对象
setComment(String) - 类 中的方法cn.hutool.db.meta.Column
设置注释
setComment(String) - 类 中的方法cn.hutool.db.meta.Table
设置注释
setCurrentDSFactory(DSFactory) - 类 中的静态方法cn.hutool.db.ds.DSFactory
设置全局的数据源工厂
在项目中存在多个连接池库的情况下,我们希望使用低优先级的库时使用此方法自定义之
重新定义全局的数据源工厂此方法可在以下两种情况下调用: 1.
setCursorName(String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setDate(int, Date) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setDate(int, Date, Calendar) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setDialect(Dialect) - 类 中的方法cn.hutool.db.SqlConnRunner
设置SQL方言
setDirection(Direction) - 类 中的方法cn.hutool.db.sql.Order
设置排序方向
setDouble(int, double) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setDriver(String) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setDriver(String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
setEscapeProcessing(boolean) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setFetchDirection(int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setFetchSize(int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setField(String) - 类 中的方法cn.hutool.db.sql.Condition
设置字段名
setField(String) - 类 中的方法cn.hutool.db.sql.Order
设置排序字段
setFieldNames(Collection<String>) - 类 中的方法cn.hutool.db.ActiveEntity
 
setFieldNames(String...) - 类 中的方法cn.hutool.db.ActiveEntity
 
setFieldNames(Collection<String>) - 类 中的方法cn.hutool.db.Entity
设置字段列表,用于限制加入的字段的值
setFieldNames(String...) - 类 中的方法cn.hutool.db.Entity
设置字段列表,用于限制加入的字段的值
setFields(Collection<String>) - 类 中的方法cn.hutool.db.sql.Query
设置查询的字段名列表
setFields(String...) - 类 中的方法cn.hutool.db.sql.Query
设置查询的字段名列表
setFloat(int, float) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setHoldability(int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setIgnoreNull(String, Object) - 类 中的方法cn.hutool.db.ActiveEntity
 
setIgnoreNull(String, Object) - 类 中的方法cn.hutool.db.Entity
 
setInitialSize(int) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setInt(int, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setLoginTimeout(int) - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
setLoginTimeout(int) - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
 
setLogWriter(PrintWriter) - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
setLogWriter(PrintWriter) - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
 
setLong(int, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setMaxActive(int) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setMaxFieldSize(int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setMaxRows(int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setMaxWait(long) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setMinIdle(int) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setName(String) - 类 中的方法cn.hutool.db.meta.Column
设置列名
setNCharacterStream(int, Reader, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNCharacterStream(int, Reader) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNClob(int, NClob) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNClob(int, Reader, long) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNClob(int, Reader) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNetworkTimeout(Executor, int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setNString(int, String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNull(int, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNull(int, int, String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setNullable(boolean) - 类 中的方法cn.hutool.db.meta.Column
设置是否为可空
setNumPerPage(int) - 类 中的方法cn.hutool.db.Page
已过时。
使用 Page.setPageSize(int) 代替
setNumPerPage(int) - 类 中的方法cn.hutool.db.PageResult
已过时。
setObject(int, Object, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setObject(int, Object) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setObject(int, Object, int, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setOperator(String) - 类 中的方法cn.hutool.db.sql.Condition
设置运算符
大于号,小于号,等于号 等
setOrder(Order...) - 类 中的方法cn.hutool.db.Page
设置排序
setPage(int) - 类 中的方法cn.hutool.db.PageResult
设置页码
setPage(Page) - 类 中的方法cn.hutool.db.sql.Query
设置分页对象
setPageNumber(int) - 类 中的方法cn.hutool.db.Page
设置页码,0表示第一页
setPageSize(int) - 类 中的方法cn.hutool.db.Page
设置每页结果数
setPageSize(int) - 类 中的方法cn.hutool.db.PageResult
设置每页结果数
setPass(String) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setPass(String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
setPkNames(Set<String>) - 类 中的方法cn.hutool.db.meta.Table
设置主键列表
setPlaceHolder(boolean) - 类 中的方法cn.hutool.db.sql.Condition
设置是否使用条件占位符
setPoolable(boolean) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setPreWrapQuote(Character) - 类 中的方法cn.hutool.db.sql.Wrapper
设置前置包装的符号
setQueryTimeout(int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setReadOnly(boolean) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setRef(int, Ref) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setRowId(int, RowId) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setRunner(SqlConnRunner) - 类 中的方法cn.hutool.db.AbstractDb
setSavepoint() - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setSavepoint(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setSavepoint() - 类 中的方法cn.hutool.db.Session
设置保存点
setSavepoint(String) - 类 中的方法cn.hutool.db.Session
设置保存点
setSchema(String) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setSecondValue(Object) - 类 中的方法cn.hutool.db.sql.Condition
设置between 类型中第二个值
setSetting(Setting) - 类 中的方法cn.hutool.db.nosql.mongo.MongoDS
设定MongoDB配置文件
setShort(int, short) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setShowSqlGlobal(Setting) - 类 中的静态方法cn.hutool.db.DbUtil
从配置文件中读取SQL打印选项
setShowSqlGlobal(boolean, boolean, boolean, Level) - 类 中的静态方法cn.hutool.db.DbUtil
设置全局配置:是否通过debug日志显示SQL
setSize(int) - 类 中的方法cn.hutool.db.meta.Column
设置大小或数据长度
setSQLXML(int, SQLXML) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setStr(String, String) - 类 中的方法cn.hutool.db.nosql.redis.RedisDS
从Redis中获取值
setString(int, String) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setSufWrapQuote(Character) - 类 中的方法cn.hutool.db.sql.Wrapper
设置后置包装的符号
setTableName(String) - 类 中的方法cn.hutool.db.ActiveEntity
 
setTableName(String) - 类 中的方法cn.hutool.db.Entity
设置表名
setTableName(String) - 类 中的方法cn.hutool.db.meta.Column
设置表名
setTableName(String) - 类 中的方法cn.hutool.db.meta.Table
设置表名
setTableNames(String...) - 类 中的方法cn.hutool.db.sql.Query
设置表名
setTime(int, Time) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setTime(int, Time, Calendar) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setTimestamp(int, Timestamp) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setTimestamp(int, Timestamp, Calendar) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setTotal(int) - 类 中的方法cn.hutool.db.PageResult
设置总数
setTotalPage(int) - 类 中的方法cn.hutool.db.PageResult
设置总页数
setTransactionIsolation(int) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setTransactionIsolation(int) - 类 中的方法cn.hutool.db.Session
设置事务的隔离级别
Connection.TRANSACTION_NONE 驱动不支持事务
Connection.TRANSACTION_READ_UNCOMMITTED 允许脏读、不可重复读和幻读
Connection.TRANSACTION_READ_COMMITTED 禁止脏读,但允许不可重复读和幻读
Connection.TRANSACTION_REPEATABLE_READ 禁止脏读和不可重复读,单运行幻读
Connection.TRANSACTION_SERIALIZABLE 禁止脏读、不可重复读和幻读
setType(int) - 类 中的方法cn.hutool.db.meta.Column
设置类型,对应java.sql.Types中的类型
setTypeMap(Map<String, Class<?>>) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
setTypeName(String) - 类 中的方法cn.hutool.db.meta.Column
设置类型名称
setUnicodeStream(int, InputStream, int) - 类 中的方法cn.hutool.db.sql.StatementWrapper
已过时。
setUrl(String) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setUrl(String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
setURL(int, URL) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
setUser(String) - 类 中的方法cn.hutool.db.ds.pooled.DbConfig
 
setUser(String) - 类 中的方法cn.hutool.db.ds.simple.SimpleDataSource
 
setValue(Object) - 类 中的方法cn.hutool.db.sql.Condition
设置值,不解析表达式
setValue(Object, boolean) - 类 中的方法cn.hutool.db.sql.Condition
设置值
setWhere(Condition...) - 类 中的方法cn.hutool.db.sql.Query
设置条件语句
setWrapper(Character) - 类 中的方法cn.hutool.db.AbstractDb
设置包装器,包装器用于对表名、字段名进行符号包装(例如双引号),防止关键字与这些表名或字段冲突
setWrapper(Wrapper) - 类 中的方法cn.hutool.db.AbstractDb
设置包装器,包装器用于对表名、字段名进行符号包装(例如双引号),防止关键字与这些表名或字段冲突
setWrapper(Character) - 类 中的方法cn.hutool.db.Db
 
setWrapper(Wrapper) - 类 中的方法cn.hutool.db.Db
 
setWrapper(Wrapper) - 接口 中的方法cn.hutool.db.dialect.Dialect
设置包装器
setWrapper(Wrapper) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
 
setWrapper(Character) - 类 中的方法cn.hutool.db.Session
 
setWrapper(Wrapper) - 类 中的方法cn.hutool.db.Session
 
setWrapper(Character) - 类 中的方法cn.hutool.db.SqlConnRunner
设置包装器,包装器用于对表名、字段名进行符号包装(例如双引号),防止关键字与这些表名或字段冲突
setWrapper(Wrapper) - 类 中的方法cn.hutool.db.SqlConnRunner
设置包装器,包装器用于对表名、字段名进行符号包装(例如双引号),防止关键字与这些表名或字段冲突
setWrapper(Character) - 类 中的方法cn.hutool.db.SqlRunner
已过时。
 
setWrapper(Wrapper) - 类 中的方法cn.hutool.db.SqlRunner
已过时。
 
SimpleDataSource - cn.hutool.db.ds.simple中的类
简易数据源,没有使用连接池,仅供测试或打开关闭连接非常少的场合使用!
SimpleDataSource() - 类 的构造器cn.hutool.db.ds.simple.SimpleDataSource
构造
SimpleDataSource(String) - 类 的构造器cn.hutool.db.ds.simple.SimpleDataSource
构造
SimpleDataSource(Setting, String) - 类 的构造器cn.hutool.db.ds.simple.SimpleDataSource
构造
SimpleDataSource(String, String, String) - 类 的构造器cn.hutool.db.ds.simple.SimpleDataSource
构造
SimpleDataSource(String, String, String, String) - 类 的构造器cn.hutool.db.ds.simple.SimpleDataSource
构造
SimpleDSFactory - cn.hutool.db.ds.simple中的类
简单数据源工厂类
SimpleDSFactory() - 类 的构造器cn.hutool.db.ds.simple.SimpleDSFactory
 
SimpleDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.simple.SimpleDSFactory
 
SqlBuilder - cn.hutool.db.sql中的类
SQL构建器
首先拼接SQL语句,值使用 ?
SqlBuilder() - 类 的构造器cn.hutool.db.sql.SqlBuilder
 
SqlBuilder(Wrapper) - 类 的构造器cn.hutool.db.sql.SqlBuilder
 
SqlBuilder.Join - cn.hutool.db.sql中的枚举
SQL中多表关联用的关键字
SqlConnRunner - cn.hutool.db中的类
SQL执行类
此执行类只接受方言参数,不需要数据源,只有在执行方法时需要数据库连接对象
此对象存在的意义在于,可以由使用者自定义数据库连接对象,并执行多个方法,方便事务的统一控制或减少连接对象的创建关闭
SqlConnRunner(Dialect) - 类 的构造器cn.hutool.db.SqlConnRunner
构造
SqlConnRunner(String) - 类 的构造器cn.hutool.db.SqlConnRunner
构造
SqlExecutor - cn.hutool.db.sql中的类
SQL执行器,全部为静态方法,执行查询或非查询的SQL语句
此方法为JDBC的简单封装,与数据库类型无关
SqlExecutor() - 类 的构造器cn.hutool.db.sql.SqlExecutor
 
SqlFormatter - cn.hutool.db.sql中的类
SQL格式化器 from Hibernate
SqlFormatter() - 类 的构造器cn.hutool.db.sql.SqlFormatter
 
Sqlite3Dialect - cn.hutool.db.dialect.impl中的类
SqlLite3方言
Sqlite3Dialect() - 类 的构造器cn.hutool.db.dialect.impl.Sqlite3Dialect
 
SqlLog - cn.hutool.db.sql中的枚举
SQL在日志中打印配置
SqlRunner - cn.hutool.db中的类
已过时。
请使用Db
SqlRunner(DataSource) - 类 的构造器cn.hutool.db.SqlRunner
已过时。
构造,从DataSource中识别方言
SqlRunner(DataSource, String) - 类 的构造器cn.hutool.db.SqlRunner
已过时。
构造
SqlRunner(DataSource, Dialect) - 类 的构造器cn.hutool.db.SqlRunner
已过时。
构造
SqlServer2012Dialect - cn.hutool.db.dialect.impl中的类
SQLServer2012 方言
SqlServer2012Dialect() - 类 的构造器cn.hutool.db.dialect.impl.SqlServer2012Dialect
 
SqlUtil - cn.hutool.db.sql中的类
SQL相关工具类,包括相关SQL语句拼接等
SqlUtil() - 类 的构造器cn.hutool.db.sql.SqlUtil
 
StatementUtil - cn.hutool.db中的类
Statement和PreparedStatement工具类
StatementUtil() - 类 的构造器cn.hutool.db.StatementUtil
 
StatementWrapper - cn.hutool.db.sql中的类
PreparedStatement 包装类,用于添加拦截方法功能
拦截方法包括: 1.
StatementWrapper() - 类 的构造器cn.hutool.db.sql.StatementWrapper
 
StringHandler - cn.hutool.db.handler中的类
处理为字符串结果,当查询结果为单个字符串时使用此处理器
StringHandler() - 类 的构造器cn.hutool.db.handler.StringHandler
 

T

Table - cn.hutool.db.meta中的类
数据库表信息
Table(String) - 类 的构造器cn.hutool.db.meta.Table
构造
tableName - 类 中的变量cn.hutool.db.DaoTemplate
表名
TableType - cn.hutool.db.meta中的枚举
元信息中表的类型
ThreadLocalConnection - cn.hutool.db中的枚举
线程相关的数据库连接持有器
此对象为单例类,用于存储线程相关的Connection对象。
ThreadLocalConnection.GroupedConnection - cn.hutool.db中的类
分组连接,根据不同的分组获取对应的连接,用于多数据源情况
ThreadLocalConnection.GroupedConnection() - 类 的构造器cn.hutool.db.ThreadLocalConnection.GroupedConnection
 
TomcatDSFactory - cn.hutool.db.ds.tomcat中的类
Tomcat-Jdbc-Pool数据源工厂类
TomcatDSFactory() - 类 的构造器cn.hutool.db.ds.tomcat.TomcatDSFactory
构造
TomcatDSFactory(Setting) - 类 的构造器cn.hutool.db.ds.tomcat.TomcatDSFactory
构造
toSqlDate(Date) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
转换为Date
toSqlTimestamp(Date) - 类 中的静态方法cn.hutool.db.sql.SqlUtil
转换为Timestamp
toString() - 类 中的方法cn.hutool.db.Entity
 
toString() - 类 中的方法cn.hutool.db.meta.Column
 
toString() - 枚举 中的方法cn.hutool.db.meta.TableType
 
toString() - 类 中的方法cn.hutool.db.Page
 
toString() - 类 中的方法cn.hutool.db.sql.Condition
 
toString(List<Object>) - 类 中的方法cn.hutool.db.sql.Condition
转换为条件字符串,并回填占位符对应的参数值
toString() - 类 中的方法cn.hutool.db.sql.Order
 
toString() - 类 中的方法cn.hutool.db.sql.SqlBuilder
 
trans(VoidFunc1<Session>) - 类 中的方法cn.hutool.db.Session
已过时。
TransactionLevel - cn.hutool.db.transaction中的枚举
事务级别枚举 脏读(Dirty Read)
一个事务会读到另一个事务更新后但未提交的数据,如果另一个事务回滚,那么当前事务读到的数据就是脏数据 不可重复读(Non Repeatable Read)
在一个事务内,多次读同一数据,在这个事务还没有结束时,如果另一个事务恰好修改了这个数据,那么,在第一个事务中,两次读取的数据就可能不一致 幻读(Phantom Read)
在一个事务中,第一次查询某条记录,发现没有,但是,当试图更新这条不存在的记录时,竟然能成功,且可以再次读取同一条记录。
tx(VoidFunc1<Db>) - 类 中的方法cn.hutool.db.Db
执行事务,使用默认的事务级别
在同一事务中,所有对数据库操作都是原子的,同时提交或者同时回滚
tx(TransactionLevel, VoidFunc1<Db>) - 类 中的方法cn.hutool.db.Db
执行事务
在同一事务中,所有对数据库操作都是原子的,同时提交或者同时回滚
tx(VoidFunc1<Session>) - 类 中的方法cn.hutool.db.Session
在事务中执行操作,通过实现VoidFunc0接口的call方法执行多条SQL语句从而完成事务
typeCode - 枚举 中的变量cn.hutool.db.meta.JdbcType
 

U

unwrap(Class<T>) - 类 中的方法cn.hutool.db.ds.DataSourceWrapper
 
unwrap(Class<T>) - 类 中的方法cn.hutool.db.ds.pooled.ConnectionWraper
 
unwrap(Class<T>) - 类 中的方法cn.hutool.db.ds.simple.AbstractDataSource
 
unwrap(Class<T>) - 类 中的方法cn.hutool.db.sql.StatementWrapper
 
update(Entity, Entity) - 类 中的方法cn.hutool.db.AbstractDb
更新数据
更新条件为多个key value对表示,默认key = value,如果使用其它条件可以使用:where.put("key", " > 1"),value也可以传Condition对象,key被忽略
update(String) - 类 中的方法cn.hutool.db.ActiveEntity
根据现有Entity中的条件删除与之匹配的数据库记录
update(Entity, Entity) - 类 中的方法cn.hutool.db.DaoTemplate
按照条件更新
update(Entity) - 类 中的方法cn.hutool.db.DaoTemplate
更新
update(Entity) - 类 中的方法cn.hutool.db.sql.SqlBuilder
更新
update(Connection, Entity, Entity) - 类 中的方法cn.hutool.db.SqlConnRunner
更新数据
此方法不会关闭Connection
use() - 类 中的静态方法cn.hutool.db.Db
创建Db
使用默认数据源,自动探测数据库连接池
use(String) - 类 中的静态方法cn.hutool.db.Db
创建Db
使用默认数据源,自动探测数据库连接池
use(DataSource) - 类 中的静态方法cn.hutool.db.Db
创建Db
会根据数据源连接的元信息识别目标数据库类型,进而使用合适的数据源
use(DataSource, Dialect) - 类 中的静态方法cn.hutool.db.Db
创建Db
use(DataSource, String) - 类 中的静态方法cn.hutool.db.Db
创建Db
use() - 类 中的静态方法cn.hutool.db.DbUtil
实例化一个新的Db,使用默认数据源
use(DataSource) - 类 中的静态方法cn.hutool.db.DbUtil
实例化一个新的Db对象
use(DataSource, Dialect) - 类 中的静态方法cn.hutool.db.DbUtil
实例化一个新的SQL运行对象

V

value() - 枚举 中的方法cn.hutool.db.meta.TableType
获取值
valueOf(String) - 枚举 中的静态方法cn.hutool.db.dialect.DialectName
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.meta.JdbcType
返回带有指定名称的该类型的枚举常量。
valueOf(int) - 枚举 中的静态方法cn.hutool.db.meta.JdbcType
通过Types中对应int值找到enum值
valueOf(String) - 枚举 中的静态方法cn.hutool.db.meta.TableType
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.sql.Condition.LikeType
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.sql.Direction
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.sql.LogicalOperator
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.sql.SqlBuilder.Join
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.sql.SqlLog
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.ThreadLocalConnection
返回带有指定名称的该类型的枚举常量。
valueOf(String) - 枚举 中的静态方法cn.hutool.db.transaction.TransactionLevel
返回带有指定名称的该类型的枚举常量。
values() - 枚举 中的静态方法cn.hutool.db.dialect.DialectName
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.meta.JdbcType
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.meta.TableType
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.sql.Condition.LikeType
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.sql.Direction
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.sql.LogicalOperator
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.sql.SqlBuilder.Join
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.sql.SqlLog
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.ThreadLocalConnection
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
values() - 枚举 中的静态方法cn.hutool.db.transaction.TransactionLevel
按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。

W

where(Condition...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
添加Where语句,所有逻辑之间为AND的关系
where(LogicalOperator, Condition...) - 类 中的方法cn.hutool.db.sql.SqlBuilder
添加Where语句
只支持单一的逻辑运算符(例如多个条件之间)
where(String) - 类 中的方法cn.hutool.db.sql.SqlBuilder
添加Where语句
wrap(DataSource, String) - 类 中的静态方法cn.hutool.db.ds.DataSourceWrapper
包装指定的DataSource
wrap(String) - 类 中的方法cn.hutool.db.sql.Wrapper
包装字段名
有时字段与SQL的某些关键字冲突,导致SQL出错,因此需要将字段名用单引号或者反引号包装起来,避免冲突
wrap(String...) - 类 中的方法cn.hutool.db.sql.Wrapper
包装字段名
有时字段与SQL的某些关键字冲突,导致SQL出错,因此需要将字段名用单引号或者反引号包装起来,避免冲突
wrap(Collection<String>) - 类 中的方法cn.hutool.db.sql.Wrapper
包装字段名
有时字段与SQL的某些关键字冲突,导致SQL出错,因此需要将字段名用单引号或者反引号包装起来,避免冲突
wrap(Entity) - 类 中的方法cn.hutool.db.sql.Wrapper
包装字段名
有时字段与SQL的某些关键字冲突,导致SQL出错,因此需要将字段名用单引号或者反引号包装起来,避免冲突
wrap(Condition...) - 类 中的方法cn.hutool.db.sql.Wrapper
包装字段名
有时字段与SQL的某些关键字冲突,导致SQL出错,因此需要将字段名用单引号或者反引号包装起来,避免冲突
wrapPageSql(SqlBuilder, Page) - 类 中的方法cn.hutool.db.dialect.impl.AnsiSqlDialect
根据不同数据库在查询SQL语句基础上包装其分页的语句
各自数据库通过重写此方法实现最小改动情况下修改分页语句
wrapPageSql(SqlBuilder, Page) - 类 中的方法cn.hutool.db.dialect.impl.H2Dialect
 
wrapPageSql(SqlBuilder, Page) - 类 中的方法cn.hutool.db.dialect.impl.MysqlDialect
 
wrapPageSql(SqlBuilder, Page) - 类 中的方法cn.hutool.db.dialect.impl.OracleDialect
 
wrapPageSql(SqlBuilder, Page) - 类 中的方法cn.hutool.db.dialect.impl.SqlServer2012Dialect
 
wrapper - 类 中的变量cn.hutool.db.dialect.impl.AnsiSqlDialect
 
Wrapper - cn.hutool.db.sql中的类
包装器
主要用于字段名的包装(在字段名的前后加字符,例如反引号来避免与数据库的关键字冲突)
Wrapper() - 类 的构造器cn.hutool.db.sql.Wrapper
 
Wrapper(Character) - 类 的构造器cn.hutool.db.sql.Wrapper
构造
Wrapper(Character, Character) - 类 的构造器cn.hutool.db.sql.Wrapper
包装符号
A B C D E F G H I J K L M N O P Q R S T U V W 

Copyright © 2019. All rights reserved.