results

package
v0.0.0-...-1eaa894 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Result

type Result struct {
	// Velero is a slice of messages related to the operation of Velero
	// itself (for example, messages related to connecting to the
	// cloud, reading a backup file, etc.)
	Velero []string `json:"velero,omitempty"`

	// Cluster is a slice of messages related to backup or restore of
	// cluster-scoped resources.
	Cluster []string `json:"cluster,omitempty"`

	// Namespaces is a map of namespace name to slice of messages
	// related to backup or restore namespace-scoped resources.
	Namespaces map[string][]string `json:"namespaces,omitempty"`
}

Result is a collection of messages that were generated during execution of a backup or restore. This will typically store either warning or error messages.

func (*Result) Add

func (r *Result) Add(ns string, e error)

Add appends an error to the provided Result, either within the cluster-scoped list (if ns == "") or within the provided namespace's entry.

func (*Result) AddVeleroError

func (r *Result) AddVeleroError(err error)

AddVeleroError appends an error to the provided Result's Velero list.

func (*Result) IsEmpty

func (r *Result) IsEmpty() bool

IsEmpty returns true if all collections of messages are empty

func (*Result) Merge

func (r *Result) Merge(other *Result)

Merge combines two Result objects into one by appending the corresponding lists to one another.

Jump to

Keyboard shortcuts

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