validator

package
v1.9.5 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2025 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllowedResponse

func AllowedResponse() *admissionv1.AdmissionResponse

AllowedResponse constructs an allowed AdmissionResonse

func DeniedResponse

func DeniedResponse(reason string, args ...interface{}) *admissionv1.AdmissionResponse

DeniedResponse constructs a denied AdmissionResonse

Types

type Validator

type Validator interface {
	ValidateCreate(context.Context) *admissionv1.AdmissionResponse
	ValidateUpdate(context.Context) *admissionv1.AdmissionResponse
}

Validator is an interface for CRD objects

func GetValidator

func GetValidator(ctx context.Context, client kubernetes.Interface, aeClient eventsclient.ArgoprojV1alpha1Interface,
	kind metav1.GroupVersionKind, oldBytes []byte, newBytes []byte) (Validator, error)

GetValidator returns a Validator instance

func NewEventBusValidator

NewEventBusValidator returns a validator for EventBus

func NewEventSourceValidator

NewEventSourceValidator returns a validator for EventSource

func NewSensorValidator

NewSensorValidator returns a validator for Sensor

Jump to

Keyboard shortcuts

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