Documentation ¶
Index ¶
Constants ¶
View Source
const ( LiteralTypeString = iota LiteralTypeBoolean LiteralTypeDecimal LiteralTypeNull )
View Source
const ( Unknown = -1 EOF = 0 )
View Source
const AND = 57361
View Source
const BOOLEAN = 57365
View Source
const COMMA = 57346
View Source
const DOT = 57347
View Source
const END = 57352
View Source
const EQUAL = 57355
View Source
const GREATER = 57353
View Source
const IDENT = 57363
View Source
const IN = 57359
View Source
const INTEGER = 57366
View Source
const LBRACK = 57350
View Source
const LESS = 57354
View Source
const LIKE = 57357
View Source
const LPAREN = 57348
View Source
const MATCH = 57358
View Source
const MINUS = 57360
View Source
const NOT = 57356
View Source
const NULL = 57367
View Source
const OR = 57362
View Source
const RBRACK = 57351
View Source
const RPAREN = 57349
View Source
const STRING = 57364
Variables ¶
View Source
var ( String = &LiteralType{Type: LiteralTypeString} Boolean = &LiteralType{Type: LiteralTypeBoolean} Decimal = &LiteralType{Type: LiteralTypeDecimal} )
View Source
var ( Greater = &OperatorType{Type: GREATER} Less = &OperatorType{Type: LESS} Equal = &OperatorType{Type: EQUAL} Not = &OperatorType{Type: NOT} Like = &OperatorType{Type: LIKE} Match = &OperatorType{Type: MATCH} In = &OperatorType{Type: IN} Minus = &OperatorType{Type: MINUS} And = &OperatorType{Type: AND} Or = &OperatorType{Type: OR} )
View Source
var Null = &LiteralExpr{ Type: &LiteralType{Type: LiteralTypeNull}, Value: "null", }
Functions ¶
Types ¶
type BinaryExpr ¶ added in v0.11.0
type BinaryExpr struct { Op []*OperatorType Left Expr Right Expr }
type ComboItem ¶ added in v0.11.0
type ComboItem any
ComboItem will only contain two types, Expr and []*OperatorType, currently, the value of Expr should only be *BinaryExpr
type Field ¶ added in v0.11.0
type Field any
Field will only contain two types, *Ident and *LiteralType, where the value of *LiteralType must be an integer
type FieldsExpr ¶ added in v0.11.0
type FieldsExpr struct {
Fields []Field
}
type LiteralExpr ¶ added in v0.11.0
type LiteralExpr struct { Type *LiteralType Value string }
type LiteralListExpr ¶ added in v0.11.0
type LiteralListExpr struct {
List []*LiteralExpr
}
type LiteralType ¶ added in v0.11.0
type LiteralType struct {
Type int
}
type OperatorType ¶ added in v0.11.0
type OperatorType struct {
Type int
}
Click to show internal directories.
Click to hide internal directories.