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

Function NewContextVariable

common/env/env.go:317–319  ·  view source on GitHub ↗

NewContextVariable returns a serializable context variable with a specific type name.

(typeName string)

Source from the content-addressed store, hash-verified

315
316// NewContextVariable returns a serializable context variable with a specific type name.
317func NewContextVariable(typeName string) *ContextVariable {
318 return &ContextVariable{TypeName: typeName}
319}
320
321// ContextVariable represents a structured message whose fields are to be treated as the top-level
322// variable identifiers within CEL expressions.

Callers 9

envProtoToConfigFunction · 0.92
ToConfigMethod · 0.92
TestEnvToConfigFunction · 0.92
TestEnvFromConfigFunction · 0.92
TestEnvFromConfigErrorsFunction · 0.92
TestConfigFunction · 0.85
TestConfigValidateErrorsFunction · 0.85
TestNewContextVariableFunction · 0.85

Calls

no outgoing calls

Tested by 7

TestEnvToConfigFunction · 0.74
TestEnvFromConfigFunction · 0.74
TestEnvFromConfigErrorsFunction · 0.74
TestConfigFunction · 0.68
TestConfigValidateErrorsFunction · 0.68
TestNewContextVariableFunction · 0.68