policy

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: May 8, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ResourceLabels

type ResourceLabels struct {
	Trigger *v1alpha1.Trigger
	Client  dynamic.NamespaceableResourceInterface
	Obj     *unstructured.Unstructured
}

ResourceLabels implements trigger policy based on the resource labels

func (*ResourceLabels) ApplyPolicy

func (rl *ResourceLabels) ApplyPolicy() error

type StatusPolicy

type StatusPolicy struct {
	// Status represents the status of a generic operation
	Status int
	// Statuses refers to list of response status allowed
	Statuses []int
}

StatusPolicy implements the policy for a HTTP trigger

func NewStatusPolicy

func NewStatusPolicy(status int, statuses []int) *StatusPolicy

NewStatusPolicy returns a new HTTP trigger policy

func (*StatusPolicy) ApplyPolicy

func (hp *StatusPolicy) ApplyPolicy() error

Jump to

Keyboard shortcuts

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