jmespath

package
v0.0.0-...-51e1a67 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2026 License: Apache-2.0 Imports: 17 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Expression

type Expression struct {
	// contains filtered or unexported fields
}

Expression represents a parsed JMESPath expression.

func MustCompile

func MustCompile(expression string) *Expression

MustCompile creates a Expression from a string, panicking if the expression is invalid.

func NewExpressionFromConfiguration

func NewExpressionFromConfiguration(config *pb.Expression, group program.Group, clock clock.Clock) (*Expression, error)

NewExpressionFromConfiguration creates a new JMESPath expression.Expression from the provided configuration. This will also evaluate all test vectors and return an error if any of them fail.

The group parameter is required when there are files and is used to schedule refreshes of the file contents.

func (*Expression) Search

func (e *Expression) Search(data map[string]any) (any, error)

Search evaluates the JMESPath expression against the provided data, returning the result as structured data.

Jump to

Keyboard shortcuts

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