cel

package
v0.0.0-...-69da28f Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsCELIdentifier

func IsCELIdentifier(name string) bool

Types

type Compiler

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

func NewCompiler

func NewCompiler() (*Compiler, error)

func (*Compiler) AddVariable

func (c *Compiler) AddVariable(name string, t *cel.Type) error

func (*Compiler) CompileCELExpression

func (c *Compiler) CompileCELExpression(expression string) (*cel.Ast, error)

func (*Compiler) EvalCELExpression

func (c *Compiler) EvalCELExpression(
	vars map[string]interface{}, ast *cel.Ast,
) (ref.Val, error)

func (*Compiler) ValidateBoolExpression

func (c *Compiler) ValidateBoolExpression(expression string) error

func (*Compiler) ValidateStringExpression

func (c *Compiler) ValidateStringExpression(expression string) error

Directories

Path Synopsis
Package library implements CEL extension functions that expose Kubewarden context-aware capabilities as CEL functions for the policy to use.
Package library implements CEL extension functions that expose Kubewarden context-aware capabilities as CEL functions for the policy to use.

Jump to

Keyboard shortcuts

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