validate

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2020 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateValueWithPattern

func ValidateValueWithPattern(value, pattern interface{}) bool

ValidateValueWithPattern validates value with operators and wildcards

Types

type ValidationError

type ValidationError struct {
	StatusCode ValidationFailureReason
	ErrorMsg   string
}

func ValidateResourceWithPattern

func ValidateResourceWithPattern(ctx context.EvalInterface, resource, pattern interface{}) (string, ValidationError)

validateResourceWithPattern is a start of element-by-element validation process It assumes that validation is started from root, so "/" is passed

type ValidationFailureReason

type ValidationFailureReason int
const (
	PathNotPresent ValidationFailureReason = iota
	Rulefailure
)

Jump to

Keyboard shortcuts

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