Documentation ¶
Index ¶
- Variables
- type Executor
- func (e *Executor) DoAst(ast *expression.AstNode, prefix, suffix string) (sqls string, params []any, keys []string)
- func (e *Executor) DoExpr(expr string, prefix, suffix string) (sqls string, params []any, keys []string, err error)
- func (e *Executor) DoTerm(term *expression.AstNode, prefix, suffix string) (sql string, params []any, keys []string)
Constants ¶
This section is empty.
Variables ¶
View Source
var StdExecutor = New(nil, nil, nil)
Functions ¶
This section is empty.
Types ¶
type Executor ¶
type Executor struct { // KeyMap 字段映射 // 存在映射 => key 转换为映射值 // // 字段存在 '.',则第一个 '.' 前面作为字段名,后面作为 json 属性名 // 不存在 '.',则整体作为字段名 KeyMap map[string]string // contains filtered or unexported fields }
func New ¶
func New(mysqlExecutor *mysql_expr.Executor, jsonExecutor *mysql_json_expr.Executor, keyMap map[string]string) *Executor
func (*Executor) DoAst ¶
func (e *Executor) DoAst(ast *expression.AstNode, prefix, suffix string) (sqls string, params []any, keys []string)
DoAst 执行 ast
Click to show internal directories.
Click to hide internal directories.