overlays

package
v0.6.5 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrOnMissingNoInjectAction occurrs if there are not matches found and no inject action present.
	ErrOnMissingNoInjectAction = errors.New("no matches and no onMissing.action of 'inject'")

	// ErrOnMissingNoInjectPath occurrs if there are no matches found for the injectPath.
	ErrOnMissingNoInjectPath = errors.New("no matches and no onMissing.injectPath")
)

Functions

This section is empty.

Types

type Condition

type Condition struct {
	Query Queries   `yaml:"query,omitempty"`
	Value yaml.Node `yaml:"value,omitempty"`
}

type DocumentQueries

type DocumentQueries []*DocumentQuery

type DocumentQuery

type DocumentQuery struct {
	Conditions []*Condition `yaml:"conditions,omitempty"`
}

type OnMissing

type OnMissing struct {
	Action     actions.OnMissingAction `yaml:"action,omitempty"`
	InjectPath Queries                 `yaml:"injectPath,omitempty"`
}

type Overlay

type Overlay struct {
	Name          string          `yaml:"name,omitempty"`
	Query         Queries         `yaml:"query,omitempty"`
	Value         yaml.Node       `yaml:"value,omitempty"`
	Action        actions.Action  `yaml:"action,omitempty"`
	DocumentQuery DocumentQueries `yaml:"documentQuery,omitempty"`
	OnMissing     OnMissing       `yaml:"onMissing,omitempty"`
	DocumentIndex []int           `yaml:"documentIndex,omitempty"`
}

func (*Overlay) Apply

func (o *Overlay) Apply(n *yaml.Node) error

func (*Overlay) CheckDocumentIndex

func (o *Overlay) CheckDocumentIndex(current int) bool

func (*Overlay) UnmarshalYAML

func (o *Overlay) UnmarshalYAML(value *yaml.Node) error

type Queries added in v0.3.0

type Queries []Query

func (*Queries) Find added in v0.3.0

func (mq *Queries) Find(node *yaml.Node) []*yaml.Node

func (*Queries) Paths added in v0.3.0

func (mq *Queries) Paths() []string

func (*Queries) Set added in v0.5.0

func (mq *Queries) Set(val string) error

func (Queries) String added in v0.3.0

func (mq Queries) String() string

func (*Queries) Type added in v0.5.0

func (mq *Queries) Type() string

func (*Queries) UnmarshalYAML added in v0.3.0

func (mq *Queries) UnmarshalYAML(value *yaml.Node) error

type Query added in v0.3.0

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

func (*Query) Find added in v0.3.0

func (q *Query) Find(node *yaml.Node) []*yaml.Node

func (Query) String added in v0.3.0

func (q Query) String() string

func (*Query) UnmarshalYAML added in v0.3.0

func (q *Query) UnmarshalYAML(value *yaml.Node) error

type WorkStream

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

func NewWorkStream

func NewWorkStream() *WorkStream

func (*WorkStream) AddWorkload

func (s *WorkStream) AddWorkload(o *Overlay, n *yaml.Node, nodeIndex int, path string)

func (*WorkStream) CloseStream

func (s *WorkStream) CloseStream()

func (*WorkStream) StartHandler

func (s *WorkStream) StartHandler() error

func (*WorkStream) StartStream

func (s *WorkStream) StartStream()

Jump to

Keyboard shortcuts

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