Documentation
¶
Index ¶
- type And
- type BoolValue
- func (n BoolValue) AsBool() (bool, error)
- func (n BoolValue) AsNumber() (float64, error)
- func (n BoolValue) AsString() (string, error)
- func (b BoolValue) Eq(other Value) (bool, error)
- func (b BoolValue) Eval(_ Context) (Value, error)
- func (b BoolValue) MarshalJSON() ([]byte, error)
- func (b BoolValue) String() string
- type ComparisonOperator
- type Context
- type ContextExpression
- type Eq
- type Expression
- type If
- type NumberValue
- type Or
- type StringValue
- type Value
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type And ¶
type And struct {
Args []Expression
}
type ComparisonOperator ¶
type ComparisonOperator struct {
First Expression
Second Expression
Comparer func(float64, float64) bool
}
type Context ¶
type Context map[string]Expression
type ContextExpression ¶
type ContextExpression struct {
Key Expression
}
type Eq ¶
type Eq struct {
Args []Expression
}
type Expression ¶
type If ¶
type If struct {
Condition Expression
Then Expression
Else Expression
}
type NumberValue ¶
type NumberValue struct {
Val float64
}
func (NumberValue) AsBool ¶
func (n NumberValue) AsBool() (bool, error)
func (NumberValue) AsNumber ¶
func (n NumberValue) AsNumber() (float64, error)
func (NumberValue) AsString ¶
func (n NumberValue) AsString() (string, error)
func (NumberValue) MarshalJSON ¶
func (n NumberValue) MarshalJSON() ([]byte, error)
type Or ¶
type Or struct {
Args []Expression
}
type StringValue ¶
type StringValue struct {
Val string
}
func (StringValue) AsBool ¶
func (n StringValue) AsBool() (bool, error)
func (StringValue) AsNumber ¶
func (n StringValue) AsNumber() (float64, error)
func (StringValue) AsString ¶
func (n StringValue) AsString() (string, error)
func (StringValue) MarshalJSON ¶
func (s StringValue) MarshalJSON() ([]byte, error)
Click to show internal directories.
Click to hide internal directories.