Package | Description |
---|---|
org.dromara.hutool.db.config |
数据库配置,通过统一的配置文件,提供灵活的配置来源,包括但不限于:
setting配置文件
XML配置文件
网络配置
自定义Bean
|
org.dromara.hutool.db.ds |
数据源封装,对各类数据库连接池的封装
数据库连接池使用工厂方法模式,当有新增连接池时,实现 DSFactory 即可。 |
org.dromara.hutool.db.ds.bee |
BeeCP封装
见:https://github.com/Chris2018998/BeeCP
|
org.dromara.hutool.db.ds.c3p0 |
C3P0封装
|
org.dromara.hutool.db.ds.dbcp |
DBCP封装
|
org.dromara.hutool.db.ds.druid |
Druid封装
|
org.dromara.hutool.db.ds.hikari |
Hikari封装
|
org.dromara.hutool.db.ds.jndi |
JNDI封装
|
org.dromara.hutool.db.ds.pooled |
Hutool对连接池的简单实现
|
org.dromara.hutool.db.ds.simple |
JDBC中DriverManager简易封装
|
org.dromara.hutool.db.ds.tomcat |
Tomcat-Pool封装
|
Modifier and Type | Class and Description |
---|---|
class |
ConnectionConfig<T extends ConnectionConfig<?>>
数据库连接配置,提供包括jdbcUrl、用户名和密码等信息
|
Modifier and Type | Class and Description |
---|---|
class |
DbConfig
数据库配置,包括:
基本配置项,如driver、url、user、password等
连接配置,如remarks、useInformationSchema等
连接池配置,如初始容量、最大容量等,取决于连接池库具体要求
其它配置,如是否大小写敏感、SQL过滤器等
|
Modifier and Type | Method and Description |
---|---|
DataSource |
DSFactory.createDataSource(ConnectionConfig<?> config)
创建数据源
|
Modifier and Type | Method and Description |
---|---|
DataSource |
BeeDSFactory.createDataSource(ConnectionConfig<?> config) |
Modifier and Type | Method and Description |
---|---|
DataSource |
C3p0DSFactory.createDataSource(ConnectionConfig<?> config) |
Modifier and Type | Method and Description |
---|---|
DataSource |
DbcpDSFactory.createDataSource(ConnectionConfig<?> config) |
Modifier and Type | Method and Description |
---|---|
DataSource |
DruidDSFactory.createDataSource(ConnectionConfig<?> config) |
Modifier and Type | Method and Description |
---|---|
DataSource |
HikariDSFactory.createDataSource(ConnectionConfig<?> config) |
Modifier and Type | Method and Description |
---|---|
DataSource |
JndiDSFactory.createDataSource(ConnectionConfig<?> config) |
Modifier and Type | Method and Description |
---|---|
DataSource |
PooledDSFactory.createDataSource(ConnectionConfig<?> config) |
Constructor and Description |
---|
PooledConnection(ConnectionConfig<?> config,
PooledDataSource dataSource)
构造
|
PooledDataSource(ConnectionConfig<?> config)
构造
|
Modifier and Type | Method and Description |
---|---|
DataSource |
SimpleDSFactory.createDataSource(ConnectionConfig<?> config) |
Constructor and Description |
---|
SimpleDataSource(ConnectionConfig<?> config)
构造
|
Modifier and Type | Method and Description |
---|---|
DataSource |
TomcatDSFactory.createDataSource(ConnectionConfig<?> config) |
Copyright © 2025. All rights reserved.