Documentation ¶
Index ¶
- func RegisterNewBinOpExpCreator(op Operator, creator BinOpExpCreator)
- type BinOpExp
- type BinOpExpCreator
- type EqualExp
- type Expression
- func NewBinOpExp(op Operator, lh, rh *Value) (Expression, *util.Result)
- func NewEqualExp(lh, rh *Value) Expression
- func NewGreaterEqExp(lh, rh *Value) Expression
- func NewGreatorExp(lh, rh *Value) Expression
- func NewIncludeExp(lh, rh *Value) Expression
- func NewLessEqExp(lh, rh *Value) Expression
- func NewLessExp(lh, rh *Value) Expression
- func NewNotEqExp(lh, rh *Value) Expression
- type GreaterEqExp
- type GreatorExp
- type IncludeExp
- type LessEqExp
- type LessExp
- type NotEqExp
- type Operator
- type Value
- func (lh *Value) And(rh *Value) *Value
- func (v *Value) Calc() *Value
- func (lh *Value) Equal(rh *Value) *Value
- func (v *Value) False() bool
- func (v *Value) HasError() bool
- func (v *Value) IsBool() bool
- func (v *Value) IsNil() bool
- func (lh *Value) Less(rh *Value) *Value
- func (lh *Value) Not() *Value
- func (lh *Value) Or(rh *Value) *Value
- func (v *Value) SetError(err *util.Result)
- func (v *Value) SetFalse() *Value
- func (v *Value) SetNum(n float64) *Value
- func (v *Value) SetText(t string) *Value
- func (v *Value) SetTrue() *Value
- func (v *Value) SetValue(s string) *Value
- func (v *Value) String() string
- func (v *Value) True() bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterNewBinOpExpCreator ¶
func RegisterNewBinOpExpCreator(op Operator, creator BinOpExpCreator)
Types ¶
type BinOpExp ¶
type BinOpExp struct { Op Operator Lh Expression Rh Expression }
type BinOpExpCreator ¶
type BinOpExpCreator func(lh *Value, rh *Value) Expression
type Expression ¶
type Expression interface {
Calc() *Value
}
func NewBinOpExp ¶
func NewBinOpExp(op Operator, lh, rh *Value) (Expression, *util.Result)
func NewEqualExp ¶
func NewEqualExp(lh, rh *Value) Expression
func NewGreaterEqExp ¶
func NewGreaterEqExp(lh, rh *Value) Expression
func NewGreatorExp ¶
func NewGreatorExp(lh, rh *Value) Expression
func NewIncludeExp ¶
func NewIncludeExp(lh, rh *Value) Expression
func NewLessEqExp ¶
func NewLessEqExp(lh, rh *Value) Expression
func NewLessExp ¶
func NewLessExp(lh, rh *Value) Expression
func NewNotEqExp ¶
func NewNotEqExp(lh, rh *Value) Expression
type GreaterEqExp ¶
type GreaterEqExp struct {
BinOpExp
}
func (GreaterEqExp) Calc ¶
func (e GreaterEqExp) Calc() *Value
type GreatorExp ¶
type GreatorExp struct {
BinOpExp
}
func (GreatorExp) Calc ¶
func (e GreatorExp) Calc() *Value
type IncludeExp ¶
type IncludeExp struct {
BinOpExp
}
func (IncludeExp) Calc ¶
func (e IncludeExp) Calc() *Value
Click to show internal directories.
Click to hide internal directories.