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

Method QualifyIfPresent

interpreter/interpretable.go:287–290  ·  view source on GitHub ↗

QualifyIfPresent returns whether the target field in the test-only expression is present.

(vars Activation, obj any, presenceOnly bool)

Source from the content-addressed store, hash-verified

285
286// QualifyIfPresent returns whether the target field in the test-only expression is present.
287func (q *testOnlyQualifier) QualifyIfPresent(vars Activation, obj any, presenceOnly bool) (any, bool, error) {
288 // Only ever test for presence.
289 return q.ConstantQualifier.QualifyIfPresent(vars, obj, true)
290}
291
292// QualifierValueEquals determines whether the test-only constant qualifier equals the input value.
293func (q *testOnlyQualifier) QualifierValueEquals(value any) bool {

Callers

nothing calls this directly

Calls 1

QualifyIfPresentMethod · 0.65

Tested by

no test coverage detected