Documentation ¶
Index ¶
- type Err
- type Instruct
- type InstructOptionFunc
- type Meta
- type MetaOptionFunc
- func WithDbName(dbName string) MetaOptionFunc
- func WithIp(ip string) MetaOptionFunc
- func WithLogger(logger log.API) MetaOptionFunc
- func WithMaxIdleConns(MaxIdleConns int) MetaOptionFunc
- func WithMaxLifeTime(MaxLifeTime time.Duration) MetaOptionFunc
- func WithPassWord(PassWord string) MetaOptionFunc
- func WithPort(port string) MetaOptionFunc
- func WithUserName(UserName string) MetaOptionFunc
- type QueryOption
- type QueryOptionFunc
- type Rdb
- func (r *Rdb) Delete(ctx context.Context, table string, where map[string]interface{}, ...) (map[string]int64, error)
- func (r *Rdb) Engine() *sqlx.DB
- func (r *Rdb) Insert(ctx context.Context, table string, data map[string]interface{}, ...) (map[string]int64, error)
- func (r *Rdb) Query(ctx context.Context, table []string, opts ...QueryOptionFunc) ([]map[string]interface{}, error)
- func (r *Rdb) Update(ctx context.Context, table string, data map[string]interface{}, ...) (map[string]int64, error)
- type SqlOption
- type Type
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type InstructOptionFunc ¶ added in v0.0.46
type InstructOptionFunc func(*instructOpts)
func WithPlaceholder ¶
func WithPlaceholder(placeholder string) InstructOptionFunc
type MetaOptionFunc ¶ added in v0.0.46
type MetaOptionFunc func(*Meta)
func WithDbName ¶
func WithDbName(dbName string) MetaOptionFunc
func WithIp ¶
func WithIp(ip string) MetaOptionFunc
func WithLogger ¶
func WithLogger(logger log.API) MetaOptionFunc
func WithMaxIdleConns ¶
func WithMaxIdleConns(MaxIdleConns int) MetaOptionFunc
func WithMaxLifeTime ¶
func WithMaxLifeTime(MaxLifeTime time.Duration) MetaOptionFunc
func WithPassWord ¶
func WithPassWord(PassWord string) MetaOptionFunc
func WithPort ¶
func WithPort(port string) MetaOptionFunc
func WithUserName ¶
func WithUserName(UserName string) MetaOptionFunc
type QueryOption ¶
type QueryOption interface {
// contains filtered or unexported methods
}
type QueryOptionFunc ¶
type QueryOptionFunc func(*SqlOption)
func WithColumn ¶
func WithColumn(column []string) QueryOptionFunc
func WithWhere ¶
func WithWhere(where map[string]interface{}) QueryOptionFunc
Click to show internal directories.
Click to hide internal directories.