Package dev.cel.runtime
Interface CelAttributeResolver
-
public interface CelAttributeResolverResolver for attribute lookups at runtime.Attributes identify resolvable parts of state available in the CEL expression.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Optional<CelUnknownSet>maybePartialUnknown(CelAttribute attr)Returns an unknown set containing the attribute if it is determined as partially unknown.java.util.Optional<java.lang.Object>resolve(CelAttribute attr)Attempts to resolve an attribute exactly.
-
-
-
Method Detail
-
resolve
java.util.Optional<java.lang.Object> resolve(CelAttribute attr)
Attempts to resolve an attribute exactly.May return an UnknownSet if the attribute is unknown, a value if it has been resolved, or Optional.empty() if the attribute isn't declared as an unknown.
-
maybePartialUnknown
java.util.Optional<CelUnknownSet> maybePartialUnknown(CelAttribute attr)
Returns an unknown set containing the attribute if it is determined as partially unknown.A partial match is defined as an attribute whose sub-elements match an unknown pattern. E.g., attribute
com.google.containeris partially unknown with patterncom.google.container.element
-
-