| 123456789101112131415161718 |
- // Author: simon (ynwdlxm@163.com)
- // Date: 2025/5/26 13:48
- // Desc:
- package resp
- // Connection 定义客户端连接接口,用于管理连接状态和数据库选择
- type Connection interface {
- // Write 向客户端写入响应数据
- Write([]byte) error
- // GetDBIndex 获取当前选择的数据库索引
- GetDBIndex() int
- // SelectDB 切换当前数据库
- SelectDB(int)
- }
|