op

package
v0.0.14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 21, 2025 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type And

type And[T any] struct {
	// contains filtered or unexported fields
}

func (*And[T]) Evaluate

func (and *And[T]) Evaluate(value T) bool

func (*And[T]) String

func (and *And[T]) String() string

type EqualEvaluator

type EqualEvaluator[T any] struct {
	// contains filtered or unexported fields
}

func (*EqualEvaluator[T]) Evaluate

func (evaluator *EqualEvaluator[T]) Evaluate(other T) bool

func (*EqualEvaluator[T]) String

func (evaluator *EqualEvaluator[T]) String() string

type Equatable

type Equatable[T any] interface {
	Equal(other any) bool
}

type Evaluator

type Evaluator[T any] interface {
	Evaluate(T) bool
}

type GreaterEvaluator

type GreaterEvaluator[T cmp.Ordered] struct {
	// contains filtered or unexported fields
}

func (*GreaterEvaluator[T]) Evaluate

func (evaluator *GreaterEvaluator[T]) Evaluate(other T) bool

func (*GreaterEvaluator[T]) String

func (evaluator *GreaterEvaluator[T]) String() string

type GreaterOrEqualEvaluator

type GreaterOrEqualEvaluator[T cmp.Ordered] struct {
	// contains filtered or unexported fields
}

func (*GreaterOrEqualEvaluator[T]) Evaluate

func (evaluator *GreaterOrEqualEvaluator[T]) Evaluate(other T) bool

func (*GreaterOrEqualEvaluator[T]) String

func (evaluator *GreaterOrEqualEvaluator[T]) String() string

type LessEvaluator

type LessEvaluator[T cmp.Ordered] struct {
	// contains filtered or unexported fields
}

func (*LessEvaluator[T]) Evaluate

func (evaluator *LessEvaluator[T]) Evaluate(other T) bool

func (*LessEvaluator[T]) String

func (evaluator *LessEvaluator[T]) String() string

type LessOrEqualEvaluator

type LessOrEqualEvaluator[T cmp.Ordered] struct {
	// contains filtered or unexported fields
}

func (*LessOrEqualEvaluator[T]) Evaluate

func (evaluator *LessOrEqualEvaluator[T]) Evaluate(other T) bool

func (*LessOrEqualEvaluator[T]) String

func (evaluator *LessOrEqualEvaluator[T]) String() string

type NotEvaluator

type NotEvaluator[T any] struct {
	// contains filtered or unexported fields
}

func (*NotEvaluator[T]) Evaluate

func (evaluator *NotEvaluator[T]) Evaluate(other T) bool

func (*NotEvaluator[T]) String

func (evaluator *NotEvaluator[T]) String() string

type Operator

type Operator[T any] struct {
	Evaluator[T]
}

func Equal

func Equal[T any](value T) Operator[T]

func Greater

func Greater[T cmp.Ordered](value T) Operator[T]

func GreaterOrEqual

func GreaterOrEqual[T cmp.Ordered](value T) Operator[T]

func In

func In[T any](values ...T) Operator[T]

func Less

func Less[T cmp.Ordered](value T) Operator[T]

func LessOrEqual

func LessOrEqual[T cmp.Ordered](value T) Operator[T]

func Not

func Not[T any](operator Operator[T]) Operator[T]

func (Operator[T]) And

func (operator Operator[T]) And(other Operator[T]) Operator[T]

func (Operator[T]) Or

func (operator Operator[T]) Or(other Operator[T]) Operator[T]

type Or

type Or[T any] struct {
	// contains filtered or unexported fields
}

func (*Or[T]) Evaluate

func (or *Or[T]) Evaluate(value T) bool

func (*Or[T]) String

func (or *Or[T]) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL