rego

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BuiltinsInspector

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

BuiltinsInspector inspect a Rego policy and returns the list of builtins used by the policy that must be provided by the runtime (SDK)

func NewInspector

func NewInspector() BuiltinsInspector

NewInspector creates a new instance of BuiltinsInspector

func (*BuiltinsInspector) InspectPolicy

func (i *BuiltinsInspector) InspectPolicy(filename string) (mapset.Set, error)

InspectPolicy loads the Rego policy from disk and then parses the AST tree looking for the builtins used by the policy.

It returns a Set with the names of the builtins used by the policy that must be provided by the SDK

Jump to

Keyboard shortcuts

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