MCPcopy Create free account
hub / github.com/cel-expr/cel-go / SetConfig

Method SetConfig

common/env/env.go:718–721  ·  view source on GitHub ↗

SetConfig sets the set of map key-value pairs associated with this validator's configuration.

(config map[string]any)

Source from the content-addressed store, hash-verified

716
717// SetConfig sets the set of map key-value pairs associated with this validator's configuration.
718func (v *Validator) SetConfig(config map[string]any) *Validator {
719 v.Config = config
720 return v
721}
722
723// ConfigValue retrieves the value associated with the config key name, if one exists.
724func (v *Validator) ConfigValue(name string) (any, bool) {

Callers 8

envToValidatorsFunction · 0.95
ToConfigMethod · 0.80
TestEnvToConfigFunction · 0.80
TestEnvFromConfigFunction · 0.80
TestEnvFromConfigErrorsFunction · 0.80
ToConfigMethod · 0.80
TestConfigFunction · 0.80
TestValidatorConfigValueFunction · 0.80

Calls

no outgoing calls

Tested by 6

TestEnvToConfigFunction · 0.64
TestEnvFromConfigFunction · 0.64
TestEnvFromConfigErrorsFunction · 0.64
ToConfigMethod · 0.64
TestConfigFunction · 0.64
TestValidatorConfigValueFunction · 0.64