lxd: github.com/lxc/lxd/lxd/filter Index | Files

package filter

import "github.com/lxc/lxd/lxd/filter"

Index

Package Files

clause.go doc.go match.go value.go

func Match Uses

func Match(obj interface{}, clauses []Clause) bool

Match returns true if the given object matches the given filter.

func ValueOf Uses

func ValueOf(obj interface{}, field string) interface{}

ValueOf returns the value of the given field.

type Clause Uses

type Clause struct {
    PrevLogical string
    Not         bool
    Field       string
    Operator    string
    Value       string
}

Clause is a single filter clause in a filter string.

func Parse Uses

func Parse(s string) ([]Clause, error)

Parse a user-provided filter string.

Package filter imports 4 packages (graph) and is imported by 6 packages. Updated 2020-01-31. Refresh now. Tools for package owners.