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

Function JSONFieldNames

cel/options.go:442–444  ·  view source on GitHub ↗

JSONFieldNames supports accessing protocol buffer fields by json-name. Enabling JSON field name support will create a copy of the types.Registry with fields indexed by JSON name, and whether JSON name or Proto-style names are supported will be inferred from the AST extensions metadata.

(enabled bool)

Source from the content-addressed store, hash-verified

440// by JSON name, and whether JSON name or Proto-style names are supported will be inferred from
441// the AST extensions metadata.
442func JSONFieldNames(enabled bool) EnvOption {
443 return features(featureJSONFieldNames, enabled)
444}
445
446// ProgramOption is a functional interface for configuring evaluation bindings and behaviors.
447type ProgramOption func(p *prog) (*prog, error)

Callers 5

OptionMethod · 0.92
TestEnvToConfigFunction · 0.70
TestJSONFieldNamesFunction · 0.70

Calls 1

featuresFunction · 0.85

Tested by 4

TestEnvToConfigFunction · 0.56
TestJSONFieldNamesFunction · 0.56