Help us shape the future of Go! Take the 2026 Go Developer Survey

handlers

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2019 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFuncBackedValidator

func NewFuncBackedValidator(log logr.Logger, scheme *runtime.Scheme, validators map[schema.GroupKind]Validator) *funcBackedValidator

Types

type ConversionHook added in v0.12.0

type ConversionHook interface {
	// Convert is called to convert a resource in one version into a different version.
	Convert(conversionSpec *apiextensionsv1beta1.ConversionRequest) *apiextensionsv1beta1.ConversionResponse
}

type MutatingAdmissionHook added in v0.12.0

type MutatingAdmissionHook interface {
	// Admit is called to decide whether to accept the admission request. The returned AdmissionResponse may
	// use the Patch field to mutate the object from the passed AdmissionRequest.
	Mutate(admissionSpec *admissionv1beta1.AdmissionRequest) *admissionv1beta1.AdmissionResponse
}

type SchemeBackedConverter added in v0.12.0

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

func NewSchemeBackedConverter added in v0.12.0

func NewSchemeBackedConverter(log logr.Logger, scheme *runtime.Scheme) *SchemeBackedConverter

func (*SchemeBackedConverter) Convert added in v0.12.0

type SchemeBackedDefaulter

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

func NewSchemeBackedDefaulter

func NewSchemeBackedDefaulter(log logr.Logger, scheme *runtime.Scheme) *SchemeBackedDefaulter

func (*SchemeBackedDefaulter) Mutate added in v0.12.0

type UpdateValidationFunc added in v0.12.0

type UpdateValidationFunc func(old, new runtime.Object) field.ErrorList

type ValidatingAdmissionHook added in v0.12.0

type ValidatingAdmissionHook interface {
	// Validate is called to decide whether to accept the admission request. The returned AdmissionResponse
	// must not use the Patch field.
	Validate(admissionSpec *admissionv1beta1.AdmissionRequest) *admissionv1beta1.AdmissionResponse
}

type ValidationFunc

type ValidationFunc func(obj runtime.Object) field.ErrorList

type Validator added in v0.12.0

type Validator interface {
	// NewObject should return the runtime.Object that should be decoded into
	// before validating the resource.
	NewObject() runtime.Object

	// Validate will validate the given resource
	Validate(runtime.Object) field.ErrorList

	// ValidateUpdate will validate the given resource for an update
	ValidateUpdate(old, new runtime.Object) field.ErrorList
}

func ValidatorFunc added in v0.12.0

func ValidatorFunc(obj runtime.Object, validate func(runtime.Object) field.ErrorList, validateUpdate func(runtime.Object, runtime.Object) field.ErrorList) Validator

Jump to

Keyboard shortcuts

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