package opa

import "github.com/open-policy-agent/opa/internal/rego/opa"

Index

Types

type EvalOpts

type EvalOpts struct {
	Input   *interface{}
	Metrics metrics.Metrics
	Time    time.Time
}

EvalOpts define options for performing an evaluation.

type OPA

type OPA struct {
}

OPA is a stub implementation of a opa.OPA.

func New

func New() *OPA

New unimplemented.

func (*OPA) Eval

func (o *OPA) Eval(ctx context.Context, opts EvalOpts) (*Result, error)

Eval unimplemented.

func (*OPA) Init

func (o *OPA) Init() (*OPA, error)

Init unimplemented.

func (*OPA) WithDataJSON

func (o *OPA) WithDataJSON(data interface{}) *OPA

WithDataJSON unimplemented.

func (*OPA) WithPolicyBytes

func (o *OPA) WithPolicyBytes(policy []byte) *OPA

WithPolicyBytes unimplemented.

type Result

type Result struct {
	Result []byte
}

Result holds the evaluation result.

Source Files

nop.go options.go

Version
v0.28.0
Published
Apr 27, 2021
Platform
js/wasm
Imports
3 packages
Last checked
6 minutes ago

Tools for package owners.