Documentation
¶
Index ¶
- type BaseDbClient
- func (b *BaseDbClient) HCount() (int64, error)
- func (b *BaseDbClient) HGet(v any) error
- func (b *BaseDbClient) HQuery(args ...*protobuf.ListParam) (*sqlx.Rows, error)
- func (b *BaseDbClient) HSelect(v any, args ...*protobuf.ListParam) error
- func (b *BaseDbClient) Sq(builder squirrel.SelectBuilder) types.DbClient
- func (b *BaseDbClient) ToSql() (string, []any, error)
- type BaseDbProvider
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseDbClient ¶ added in v1.0.58
func (*BaseDbClient) HCount ¶ added in v1.0.58
func (b *BaseDbClient) HCount() (int64, error)
func (*BaseDbClient) HGet ¶ added in v1.0.58
func (b *BaseDbClient) HGet(v any) error
func (*BaseDbClient) HSelect ¶ added in v1.0.58
func (b *BaseDbClient) HSelect(v any, args ...*protobuf.ListParam) error
func (*BaseDbClient) Sq ¶ added in v1.0.58
func (b *BaseDbClient) Sq(builder squirrel.SelectBuilder) types.DbClient
type BaseDbProvider ¶
type BaseDbProvider struct {
Default *BaseDbClient // 缺省的数据库连接
Main *BaseDbClient // 主数据库连接,可读写
Slaves []*BaseDbClient // 只读从数据库列表,只可读
Items map[string]*BaseDbClient // 额外数据库
}
func (*BaseDbProvider) Master ¶
func (b *BaseDbProvider) Master() types.DbClient
func (*BaseDbProvider) My ¶
func (b *BaseDbProvider) My() types.DbClient
Directories
¶
| Path | Synopsis |
|---|---|
|
Package mysql @Title log capability of zerolog @Description zerolog implementation of log capability @Author Ryan Fan 2021-06-09 @Update Ryan Fan 2021-06-09
|
Package mysql @Title log capability of zerolog @Description zerolog implementation of log capability @Author Ryan Fan 2021-06-09 @Update Ryan Fan 2021-06-09 |
Click to show internal directories.
Click to hide internal directories.