predicate

package
v0.0.0-...-dc362a7 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package predicate contains all event filters of the project

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CompositePredicate

type CompositePredicate struct {
	Context                 context.Context
	NonAdminBackupPredicate NonAdminBackupPredicate
	VeleroBackupPredicate   VeleroBackupPredicate
}

CompositePredicate is a combination of all project event filters

func (CompositePredicate) Create

func (p CompositePredicate) Create(evt event.CreateEvent) bool

Create event filter

func (CompositePredicate) Delete

func (p CompositePredicate) Delete(evt event.DeleteEvent) bool

Delete event filter

func (CompositePredicate) Generic

func (p CompositePredicate) Generic(evt event.GenericEvent) bool

Generic event filter

func (CompositePredicate) Update

func (p CompositePredicate) Update(evt event.UpdateEvent) bool

Update event filter

type NonAdminBackupPredicate

type NonAdminBackupPredicate struct {
	Logger logr.Logger
}

NonAdminBackupPredicate contains event filters for Non Admin Backup objects

func (NonAdminBackupPredicate) Create

Create event filter

func (NonAdminBackupPredicate) Delete

Delete event filter

func (NonAdminBackupPredicate) Generic

Generic event filter

func (NonAdminBackupPredicate) Update

Update event filter

type VeleroBackupPredicate

type VeleroBackupPredicate struct {
	// We are watching only Velero Backup objects within
	// namespace where OADP is.
	OadpVeleroNamespace string
	Logger              logr.Logger
}

VeleroBackupPredicate contains event filters for Velero Backup objects

func (VeleroBackupPredicate) Create

func (veleroBackupPredicate VeleroBackupPredicate) Create(ctx context.Context, evt event.CreateEvent) bool

Create event filter

func (VeleroBackupPredicate) Delete

Delete event filter

func (VeleroBackupPredicate) Generic

Generic event filter

func (VeleroBackupPredicate) Update

func (veleroBackupPredicate VeleroBackupPredicate) Update(ctx context.Context, evt event.UpdateEvent) bool

Update event filter

Jump to

Keyboard shortcuts

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