multierror

package
v0.5.0-nightly.20221229 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Append

func Append(err error, errs ...error) error

Append will combine all errors into a single error. Any nil errors will be skipped, only actual errors are retained. If only one error is supplied it will be returned directly. If no error is supplied the function will return nil. Otherwise an Error will be returned containing the errors as sub-errors.

Types

type Error

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

Error is an error that contains multiple sub-errors.

func (*Error) Error

func (e *Error) Error() string

Error formats all sub-error messages into a string separated with new lines.

func (*Error) Errors

func (e *Error) Errors() []error

Errors returns all underlying errors.

Jump to

Keyboard shortcuts

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