query

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2023 License: AGPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MatchAll

func MatchAll[T Value](value T, filters ...Filter[T]) bool

func MatchOne

func MatchOne[T Value](value T, filters ...Filter[T]) bool

Types

type After

type After[T Value] time.Time

func (After[T]) Match

func (op After[T]) Match(value T) bool

type And

type And[T Value] [2]Filter[T]

func (And[T]) Match

func (op And[T]) Match(value T) bool

type Before

type Before[T Value] time.Time

func (Before[T]) Match

func (op Before[T]) Match(value T) bool

type Filter

type Filter[T Value] interface {
	Match(T) bool
}

type Match

type Match[T Value] [2]string

func (Match[T]) Match

func (op Match[T]) Match(value T) bool

type Not

type Not[T Value] [1]Filter[T]

func (Not[T]) Match

func (op Not[T]) Match(value T) bool

type Or

type Or[T Value] [2]Filter[T]

func (Or[T]) Match

func (op Or[T]) Match(value T) bool

type Value

type Value interface {
	After(time.Time) bool
	Before(time.Time) bool
	Match(name, value string) bool
}

Jump to

Keyboard shortcuts

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