diff --git a/README.md b/README.md index c3a7216..82ecb5b 100644 --- a/README.md +++ b/README.md @@ -19,8 +19,9 @@ | **go/shell** | v1.0.4 | 终端样式; 命令执行; 命令链管道 | cast | [./shell/README.md](https://apigo.cc/go/shell) | | **go/config** | v1.0.4 | 文件配置加载; 环境覆盖; 结构映射 | cast, convert, file | [./config/README.md](https://apigo.cc/go/config) | | **go/log** | v1.0.0 | 高性能日志; 脱敏; 多输出渠道 | cast, config, shell | [./log/README.md](https://apigo.cc/go/log) | -| **go/http** | v1.0.2 | 高性能 HTTP 客户端; 泛型绑定; 自动透传 | cast, convert, file, log | [./http/README.md](https://apigo.cc/go/http) | -| **go/redis** | v1.0.1 | 高性能 Redis 客户端; 分布式 ID; 发布订阅 | cast, config, crypto, id, log, safe | [./redis/README.md](https://apigo.cc/go/redis) | +| **go/http** | v1.0.3 | 高性能 HTTP 客户端; 泛型绑定; 自动透传 | cast, convert, file, log | [./http/README.md](https://apigo.cc/go/http) | +| **go/db** | v1.0.1 | 极简数据库抽象; 自动绑定; 读写分离 | cast, config, convert, crypto, id, log, rand, safe, shell | [./db/README.md](https://apigo.cc/go/db) | +| **go/redis** | v1.0.2 | 高性能 Redis 客户端; 分布式 ID; 发布订阅 | cast, config, crypto, id, log, safe | [./redis/README.md](https://apigo.cc/go/redis) | --- @@ -40,7 +41,7 @@ - **API**: - **核心**: GetRedis, NewRedis, Do - **结果绑定**: To[T], Int, String, Bool, ResultMap - - **扩展能力**: Subscribe, PUBLISH, NewIdMaker + - **扩展能力**: Subscribe, PUBLISH, NewIDMaker ### convert (深度映射与平展) - **意图**: 智能递归对象映射,支持单值/切片穿透,Key 大小写模糊匹配。 @@ -101,3 +102,11 @@ - **请求**: Get, Post, Put, Delete, Head, MPost (Multipart) - **响应 (Result)**: String, Bytes, To, ToT (泛型), Save - **工具**: RelayHeaders (透传列表) + +### db (极简数据库抽象) +- **意图**: 意图优先的数据库交互层。自动处理结果绑定、连接池与读写分离,提供 SQL 自动化生成与内存安全防护。 +- **API**: + - **核心**: GetDB, GetDBWithoutCache, SetEncryptKeys + - **操作**: Insert, Replace, Update, Delete, Exec, Query, Prepare, Begin + - **结果绑定**: To, MapResults, SliceResults, StringMapResults, StringSliceResults, MapOnR1, StringMapOnR1, IntsOnC1, StringsOnC1, IntOnR1C1, FloatOnR1C1, StringOnR1C1, ToKV +, ToKV