require

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2026 License: Apache-2.0 Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder interface {
	WithGVK(apiVersion, kind string) RequirementBuilder
	WithRO(object runtime.Object) ROBuilder
}

func As

func As(objectName string) Builder

type ROBuilder

type ROBuilder interface {
	RequirementBuilder
	WithVersion(version string) ROBuilder
	WithScheme(scheme runtime.Scheme) ROBuilder
	WithNamespace(namespace *string) ROBuilder
}

type Requirement

type Requirement interface {
	Get() (name string, selector *fnv1.ResourceSelector, err error)
}

type RequirementBuilder

type RequirementBuilder interface {
	MatchName(resourceName string) Requirement
	MatchLabels(labels map[string]string) Requirement
}

type Requirements

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

func Requires

func Requires(requirements ...Requirement) (*Requirements, error)

Requires returns a new Requirements instance that requires the given extra resources.

func (*Requirements) Assure

func (r *Requirements) Assure(req *fnv1.RunFunctionRequest) (provided bool, err error)

Assure checks if the requirements are met in the given request. If not, it returns false.

func (*Requirements) Register

func (r *Requirements) Register(rsp *fnv1.RunFunctionResponse)

Register registers the requirements in the given response.

Jump to

Keyboard shortcuts

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