MCPcopy Create free account
hub / github.com/kubernetes-sigs/controller-runtime / WithFieldValidation

Function WithFieldValidation

pkg/client/fieldvalidation.go:33–39  ·  view source on GitHub ↗

WithFieldValidation wraps a Client and configures field validation, by default, for all write requests from this client. Users can override field validation for individual write requests. This wrapper has no effect on apply requests, as they do not support a custom fieldValidation setting, it is al

(c Client, validation FieldValidation)

Source from the content-addressed store, hash-verified

31// This wrapper has no effect on apply requests, as they do not support a
32// custom fieldValidation setting, it is always strict.
33func WithFieldValidation(c Client, validation FieldValidation) Client {
34 return &clientWithFieldValidation{
35 validation: validation,
36 client: c,
37 Reader: c,
38 }
39}
40
41type clientWithFieldValidation struct {
42 validation FieldValidation

Callers 4

NewFunction · 0.85

Calls

no outgoing calls

Used in the wild real call sites across dependent graphs

searching dependent graphs…