Documentation
¶
Index ¶
Constants ¶
View Source
const ( Identifier = iota String Number Boolean Null Equals Add Subtract Multiply Divide Gt Gte Lt Lte And Or Not Contains In StartsWith EndsWith OpenBracket CloseBracket Comma OpenParen CloseParen )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ErrInvalidBool ¶
type ErrInvalidBool struct {
// contains filtered or unexported fields
}
ErrInvalidBool represents an invalid boolean
func (ErrInvalidBool) Error ¶
func (e ErrInvalidBool) Error() string
type ErrInvalidIdentifier ¶
type ErrInvalidIdentifier struct {
// contains filtered or unexported fields
}
ErrInvalidIdentifier represents an invalid identifier string
func (ErrInvalidIdentifier) Error ¶
func (e ErrInvalidIdentifier) Error() string
type ErrInvalidKeyword ¶
type ErrInvalidKeyword struct {
// contains filtered or unexported fields
}
ErrInvalidKeyword represents an invalid keyword keyword
func (ErrInvalidKeyword) Error ¶
func (e ErrInvalidKeyword) Error() string
type ErrInvalidNumber ¶
type ErrInvalidNumber struct {
// contains filtered or unexported fields
}
ErrInvalidNumber represents an invalid number
func (ErrInvalidNumber) Error ¶
func (e ErrInvalidNumber) Error() string
type ErrUnsupportedCharacter ¶
type ErrUnsupportedCharacter struct {
// contains filtered or unexported fields
}
ErrUnsupportedCharacter represents an unsupported character is expression being lexed.
func (ErrUnsupportedCharacter) Error ¶
func (e ErrUnsupportedCharacter) Error() string
type ErrUnsupportedTypeComparison ¶
type ErrUnsupportedTypeComparison struct {
// contains filtered or unexported fields
}
ErrUnsupportedTypeComparison represents a comparison of incompatible types
func (ErrUnsupportedTypeComparison) Error ¶
func (e ErrUnsupportedTypeComparison) Error() string
type ErrUnterminatedString ¶
type ErrUnterminatedString struct {
// contains filtered or unexported fields
}
ErrUnterminatedString represents an unterminated string
func (ErrUnterminatedString) Error ¶
func (e ErrUnterminatedString) Error() string
type Expression ¶
type Expression interface { // Calculate will execute the parsed expression and apply it against the supplied data. // // # Errors // // Will return `Err` if the expression cannot be applied to the supplied data due to invalid // data type comparisons. Calculate(src []byte) (any, error) }
func Parse ¶
func Parse(expression []byte) (Expression, error)
Parse lex's' the provided expression and returns an Expression to be used/applied to data.
type LexerResult ¶
type LexerResult struct {
// contains filtered or unexported fields
}
LexerResult represents a token lexed result
Click to show internal directories.
Click to hide internal directories.