Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArrayOperator ¶
type ArrayOperator struct {
// contains filtered or unexported fields
}
ArrayOperator handles array operations like map, filter, reduce, all, some, none, merge
func NewArrayOperator ¶
func NewArrayOperator(config *OperatorConfig) *ArrayOperator
NewArrayOperator creates a new ArrayOperator instance with optional config
type ComparisonOperator ¶
type ComparisonOperator struct {
// contains filtered or unexported fields
}
ComparisonOperator handles comparison operators (==, ===, !=, !==, >, >=, <, <=)
func NewComparisonOperator ¶
func NewComparisonOperator(config *OperatorConfig) *ComparisonOperator
NewComparisonOperator creates a new comparison operator with optional config
type DataOperator ¶
type DataOperator struct {
// contains filtered or unexported fields
}
DataOperator handles data access operators (var, missing, missing_some)
func NewDataOperator ¶
func NewDataOperator(config *OperatorConfig) *DataOperator
NewDataOperator creates a new data operator with optional config
type LogicalOperator ¶
type LogicalOperator struct {
// contains filtered or unexported fields
}
LogicalOperator handles logical operators (and, or, !, !!, if)
func NewLogicalOperator ¶
func NewLogicalOperator(config *OperatorConfig) *LogicalOperator
NewLogicalOperator creates a new logical operator with optional config
type NumericOperator ¶
type NumericOperator struct {
// contains filtered or unexported fields
}
NumericOperator handles numeric operations like +, -, *, /, %, max, min
func NewNumericOperator ¶
func NewNumericOperator(config *OperatorConfig) *NumericOperator
NewNumericOperator creates a new NumericOperator instance with optional config
type OperatorConfig ¶ added in v1.0.1
type OperatorConfig struct {
Schema SchemaProvider
}
OperatorConfig holds shared configuration for all operators. By using a shared config object, all operators automatically see configuration changes without requiring individual SetSchema calls.
func NewOperatorConfig ¶ added in v1.0.1
func NewOperatorConfig(schema SchemaProvider) *OperatorConfig
NewOperatorConfig creates a new operator config with optional schema
func (*OperatorConfig) HasSchema ¶ added in v1.0.1
func (c *OperatorConfig) HasSchema() bool
HasSchema returns true if a schema is configured
type SchemaProvider ¶ added in v1.0.1
type SchemaProvider interface {
// HasField checks if a field exists in the schema
HasField(fieldName string) bool
// GetFieldType returns the type of a field as a string, or empty string if not found
GetFieldType(fieldName string) string
// ValidateField checks if a field exists and returns an error if not
ValidateField(fieldName string) error
// IsArrayType checks if a field is of array type
IsArrayType(fieldName string) bool
// IsStringType checks if a field is of string type
IsStringType(fieldName string) bool
// IsNumericType checks if a field is of numeric type (integer or number)
IsNumericType(fieldName string) bool
// IsBooleanType checks if a field is of boolean type
IsBooleanType(fieldName string) bool
// IsEnumType checks if a field is of enum type
IsEnumType(fieldName string) bool
// GetAllowedValues returns the allowed values for an enum field
GetAllowedValues(fieldName string) []string
// ValidateEnumValue checks if a value is valid for an enum field
ValidateEnumValue(fieldName string, value string) error
}
SchemaProvider provides schema information for field validation and type checking
type StringOperator ¶
type StringOperator struct {
// contains filtered or unexported fields
}
StringOperator handles string operations like cat, substr
func NewStringOperator ¶
func NewStringOperator(config *OperatorConfig) *StringOperator
NewStringOperator creates a new StringOperator instance with optional config