cue

package
v1.26.1 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2023 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrValidationFailed = errors.New("validation failed")
)

Functions

This section is empty.

Types

type Error

type Error struct {
	Message  string   `json:"message"`
	Location Location `json:"location"`
}

Error is a collection of fields that represent positions in files where the user has made some kind of error.

type FeaturesValidator added in v1.23.2

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

func NewFeaturesValidator added in v1.23.2

func NewFeaturesValidator() (*FeaturesValidator, error)

func (FeaturesValidator) Validate added in v1.23.2

func (v FeaturesValidator) Validate(file string, b []byte) (Result, error)

Validate validates a YAML file against our cue definition of features.

type Location

type Location struct {
	File   string `json:"file,omitempty"`
	Line   int    `json:"line"`
	Column int    `json:"column"`
}

Location contains information about where an error has occurred during cue validation.

type Result added in v1.23.2

type Result struct {
	Errors []Error `json:"errors"`
}

Result is a collection of errors that occurred during validation.

Jump to

Keyboard shortcuts

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