predicate

package
v1.2.16 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IgnoreFuncs

type IgnoreFuncs struct {
	// Create returns false if the Create event should be processed.
	CreateFunc func(event.CreateEvent) bool

	// Delete returns false if the Delete event should be processed.
	DeleteFunc func(event.DeleteEvent) bool

	// Update returns false if the Update event should be processed.
	UpdateFunc func(event.UpdateEvent) bool

	// Generic returns false if the Generic event should be processed.
	GenericFunc func(event.GenericEvent) bool
}

IgnoreFuncs is a function that implements Predicate, defaulting to ignore all events.

It's the opposite of sigs.k8s.io/controller-runtime/pkg/predicate.Funcs

IgnoreFuncs is intended to be embedded in a controller-specifc Predicate struct, with one or more methods overridden.

func (IgnoreFuncs) Create

func (p IgnoreFuncs) Create(e event.CreateEvent) bool

Create implements Predicate.

func (IgnoreFuncs) Delete

func (p IgnoreFuncs) Delete(e event.DeleteEvent) bool

Delete implements Predicate.

func (IgnoreFuncs) Generic

func (p IgnoreFuncs) Generic(e event.GenericEvent) bool

Generic implements Predicate.

func (IgnoreFuncs) Update

func (p IgnoreFuncs) Update(e event.UpdateEvent) bool

Update implements Predicate.

Jump to

Keyboard shortcuts

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