filters

package
v0.87.0 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2026 License: Apache-2.0 Imports: 15 Imported by: 8

Documentation

Overview

Package filters contains core implementations of the ComponentFilterStrategy interface.

Package filters contains core implementations of the ComponentFilterStrategy interface.

Package filters contains core implementations of the ComponentFilterStrategy interface.

Package filters contains core implementations of the ComponentFilterStrategy interface.

Package filters contains core implementations of the ComponentFilterStrategy interface.

Package filters contains core implementations of the ComponentFilterStrategy interface.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrMultipleSameGroup    = fmt.Errorf("cannot specify multiple components from the same group")
	ErrNoDefaultOrSelection = fmt.Errorf("no default or selected component found")
	ErrNotFound             = fmt.Errorf("no compatible components found")
	ErrSelectionCanceled    = fmt.Errorf("selection canceled")
)

Errors for the deployment filter.

View Source
var ErrLocalOSRequired = errors.New("localOS is required")

ErrLocalOSRequired is returned when localOS is not set.

Functions

func Apply added in v0.84.0

func Apply(definition api.Package, filter ComponentFilterStrategy) (api.Package, error)

Apply applies a component filter to a package definition.

Types

type ComponentFilterStrategy

type ComponentFilterStrategy interface {
	// Apply returns the components to keep, in order.
	Apply(api.Package) ([]api.Component, error)
}

ComponentFilterStrategy is a strategy interface for filtering components.

func ByLocalOS

func ByLocalOS(localOS string) ComponentFilterStrategy

ByLocalOS creates a new filter that filters components based on local (runtime) OS.

func BySelectState

func BySelectState(optionalComponents string) ComponentFilterStrategy

BySelectState creates a new simple included filter.

func Combine

Combine creates a new filter that applies a sequence of filters.

func Empty

Empty returns a filter that does nothing.

func ForDeploy

func ForDeploy(optionalComponents string, isInteractive bool) ComponentFilterStrategy

ForDeploy creates a new deployment filter.

Jump to

Keyboard shortcuts

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