Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cel-expr/cel-go
/ functions
Functions
9,178 in github.com/cel-expr/cel-go
⨍
Functions
9,178
◇
Types & classes
1,189
↓ 11 callers
Method
NewMapEntry
NewMapEntry creates a MapEntry with a given key, value, and a flag indicating whether the key is optionally set.
common/ast/factory.go:62
↓ 11 callers
Method
NewQualifier
NewQualifier creates a qualifier on the target object with a given value. The 'val' may be an Attribute or any proto-supported map key type: bool, in
interpreter/attributes.go:62
↓ 11 callers
Function
NewTracker
NewTracker creates a new Tracker with a given estimator and a set of functional TrackerOption values. The Tracker's configuration is fixed once it is
common/cost/tracker.go:137
↓ 11 callers
Function
NewTypeParam
NewTypeParam describe a type-param type.
common/env/env.go:785
↓ 11 callers
Method
Number
()
test/proto3pb/test_all_types.pb.go:70
↓ 11 callers
Method
Parse
Parse parses the expression represented by source and returns the result.
parser/parser.go:88
↓ 11 callers
Method
PartialVars
PartialVars returns a PartialActivation where all variables not in the input variable set, but which have been configured in the environment, are mark
cel/env.go:895
↓ 11 callers
Method
Pop
Pop returns the parent frame, releasing the current frame back to the pool.
interpreter/frame.go:226
↓ 11 callers
Method
QualString
QualString adds a string qualifier pattern to the AttributePattern. The string may be a valid identifier, or string map key including empty string.
interpreter/attribute_patterns.go:63
↓ 11 callers
Function
Regex
Regex returns a cel.EnvOption to configure extended functions for regular expression operations. Note: all functions use the 'regex' namespace. If yo
ext/regex.go:102
↓ 11 callers
Method
Result
Result returns the comprehension result expression.
common/ast/expr.go:301
↓ 11 callers
Function
SafeMultiplyByFactor
SafeMultiplyByFactor multiplies a value by a cost factor and returns the nearest integer value, rounded up, saturating at math.MaxUint64.
common/cost/cost.go:115
↓ 11 callers
Method
SetContext
SetContext sets the context for the execution frame.
interpreter/frame.go:158
↓ 11 callers
Function
Sub
Sub creates an expression representing lhs - rhs, saturated at zero.
common/cost/model.go:687
↓ 11 callers
Function
TypeToExprType
TypeToExprType converts a CEL-native type representation to a protobuf CEL Type representation.
common/types/types.go:628
↓ 11 callers
Function
UnaryBinding
UnaryBinding provides the implementation of a unary overload. The provided function is protected by a runtime type-guard which ensures runtime type ag
common/decls/decls.go:998
↓ 11 callers
Function
VariableDecls
VariableDecls configures a set of fully defined cel.VariableDecl instances in the environment.
cel/decls.go:157
↓ 11 callers
Function
duration
(seconds, nanos int64)
common/types/duration_test.go:267
↓ 11 callers
Method
getPath
getPath returns the tracked field path for an expression node, resolving through local variables if needed.
common/cost/estimator.go:1096
↓ 11 callers
Method
len
()
common/types/list.go:790
↓ 11 callers
Method
newExpr
(id int64, e exprKindCase)
common/ast/factory.go:316
↓ 11 callers
Function
newTestEnv
(t testing.TB, cont *containers.Container, reg *types.Registry)
interpreter/interpreter_test.go:2801
↓ 11 callers
Function
safeGetFieldByIndex
(v reflect.Value, index []int)
common/types/native.go:802
↓ 10 callers
Function
Abbrevs
Abbrevs configures a set of simple names as abbreviations for fully-qualified names. An abbreviation (abbrev for short) is a simple name that expands
cel/options.go:332
↓ 10 callers
Method
Add
Add adds the costs and returns the sum. If add would result in an uint64 overflow for the min or max, the value is set to math.MaxUint64.
common/cost/cost.go:349
↓ 10 callers
Function
AllocList
AllocList creates an expression representing the cost of a call that allocates a list: CallCost + ListCreateBaseCost plus the given work terms.
common/cost/model.go:938
↓ 10 callers
Method
Column
1-based line number within source.
common/location.go:20
↓ 10 callers
Function
CrossTypeNumericComparisons
CrossTypeNumericComparisons toggles type-checker support for numeric comparisons across type See https://github.com/google/cel-spec/wiki/proposal-210
checker/options.go:45
↓ 10 callers
Function
FormatCELType
FormatCELType formats a types.Type value to a string representation. The type formatting is identical to FormatCheckedType.
checker/format.go:109
↓ 10 callers
Function
FunctionBinding
FunctionBinding provides the implementation of a variadic overload. The provided function is protected by a runtime type-guard which ensures runtime t
common/decls/decls.go:1034
↓ 10 callers
Method
FunctionEstimatorWithOptions
FunctionEstimatorWithOptions returns a FunctionEstimator implementing the cost model, configured by the supplied options. Unset options take their def
common/cost/model.go:1211
↓ 10 callers
Method
GetOp
GetOp returns the op token.
repl/parser/commands_parser.go:4377
↓ 10 callers
Method
Index
Index implements (antlr.CharStream).Index.
parser/input.go:66
↓ 10 callers
Method
IsSet
IsSet returns true if the field is defined and set to a non-default value. The method will return false if defined and not set, and an error if the fi
common/types/traits/field_tester.go:29
↓ 10 callers
Function
KindMatcher
KindMatcher returns an ExprMatcher which will return true if the input NavigableExpr.Kind() matches the specified `kind`.
common/ast/navigable.go:78
↓ 10 callers
Function
LateFunctionBinding
LateFunctionBinding indicates that the function has a binding which is not known at compile time. This is useful for functions which have side-effects
cel/decls.go:352
↓ 10 callers
Method
NewAccuIdent
NewAccuIdent returns an accumulator identifier for use with comprehension results.
parser/macro.go:273
↓ 10 callers
Method
NewComprehension
NewComprehension creates a new one-variable comprehension instruction. - iterRange represents the expression that resolves to a list or map where the
parser/macro.go:236
↓ 10 callers
Function
NewEmptyRegistry
NewEmptyRegistry returns a registry which is completely unconfigured.
common/types/provider.go:190
↓ 10 callers
Function
NewExprVisitor
NewExprVisitor creates a visitor which only visits expression nodes.
common/ast/navigable.go:167
↓ 10 callers
Function
NewFunction
NewFunction creates a serializable function and overload set.
common/env/env.go:341
↓ 10 callers
Method
NewIdent
NewIdent creates an identifier Expr value.
parser/macro.go:270
↓ 10 callers
Function
NewIdentReference
NewIdentReference creates a ReferenceInfo instance for an identifier with an optional constant value.
common/ast/ast.go:490
↓ 10 callers
Function
NewImport
NewImport returns a serializable import value from the qualified type name.
common/env/env.go:222
↓ 10 callers
Method
NewSelect
NewSelect creates an Expr representing a field selection on an operand expression.
common/ast/factory.go:68
↓ 10 callers
Function
NewStringStringMap
NewStringStringMap returns a specialized traits.Mapper with string keys and values.
common/types/map.go:85
↓ 10 callers
Function
ParseStructTags
ParseStructTags configures if native types field names should be overridable by CEL struct tags. This is equivalent to ParseStructTag("cel"). A tag s
common/types/native.go:127
↓ 10 callers
Method
Push
Push pushes the given activation onto the activation stack and returns the new frame. This operation is internal to the interpreter and is used to ha
interpreter/frame.go:213
↓ 10 callers
Method
RegisterType
RegisterType registers a type value with the provider which ensures the provider is aware of how to map the type to an identifier. If the `ref.Type`
common/types/provider.go:516
↓ 10 callers
Method
SetCompletions
SetCompletions configures a channel to receive callIDs when asynchronous evaluations finish.
interpreter/frame.go:442
↓ 10 callers
Method
Subtract
Subtract returns the result of subtracting the input from the current value.
common/types/traits/math.go:61
↓ 10 callers
Method
Union
Union returns a SizeEstimate that encompasses both input SizeEstimate values.
common/cost/cost.go:281
↓ 10 callers
Method
assertYAMLType
(id int64, node *yaml.Node, nodeTypes ...yamlNodeType)
policy/parser.go:946
↓ 10 callers
Method
computeSize
computeSize resolves the size estimate for an expression, caching the result when found.
common/cost/estimator.go:1211
↓ 10 callers
Method
cost
cost recursively calculates the cost estimate for an expression node.
common/cost/estimator.go:345
↓ 10 callers
Function
features
features sets the given feature flags. See list of Feature constants above.
cel/options.go:1155
↓ 10 callers
Function
inTimeZone
(ts, tz ref.Val)
common/stdlib/standard.go:1050
↓ 10 callers
Function
isError
(val ref.Val)
interpreter/interpretable.go:2215
↓ 10 callers
Method
isRecoveryLimitExceeded
()
parser/pratt_parser.go:156
↓ 10 callers
Method
reportError
(ctx any, format string, args ...any)
parser/pratt_parser.go:308
↓ 10 callers
Method
setType
(e ast.Expr, t *types.Type)
checker/checker.go:668
↓ 10 callers
Function
testCheckCost
testCheckCost asserts the estimated cost at the latest cost model revision and at ModelVersion0, so that a case the revision moved shows both numbers
ext/sets_test.go:517
↓ 10 callers
Function
timeZone
(tz ref.Val, visitor timestampVisitor)
common/types/timestamp.go:441
↓ 10 callers
Method
tokenText
(tok token)
parser/pratt_parser.go:258
↓ 9 callers
Method
AddExtensions
AddExtensions appends a set of extensions to the config.
common/env/env.go:198
↓ 9 callers
Method
AddLetFn
AddLetFn adds a let function to the evaluation context.
repl/evaluator.go:626
↓ 9 callers
Method
AddValidators
AddValidators appends one or more validators to the config.
common/env/env.go:204
↓ 9 callers
Function
ArgElem
ArgElem creates an expression referencing the element size of the argument at the given index.
common/cost/model.go:233
↓ 9 callers
Function
AstToCheckedExpr
AstToCheckedExpr converts an Ast to an protobuf CheckedExpr value. If the Ast.IsChecked() returns false, this conversion method will return an error.
cel/io.go:66
↓ 9 callers
Function
AtLeastOneQuantity
AtLeastOneQuantity creates an expression ensuring the quantity is at least 1.
common/cost/model.go:922
↓ 9 callers
Method
CollectMetadata
CollectMetadata records the source position information of a given YAML node, and returns the id associated with the source metadata which is returned
policy/parser.go:434
↓ 9 callers
Method
ComputedSize
ComputedSize returns a size estimate of the AstNode derived from information available in the CEL expression. For constants and inline list and map de
common/cost/estimator.go:60
↓ 9 callers
Function
CustomTypeAdapter
CustomTypeAdapter swaps the default types.Adapter implementation with a custom one. Note: This option must be specified before the Types and TypeDesc
cel/options.go:172
↓ 9 callers
Method
DispatchPendingAsyncCalls
DispatchPendingAsyncCalls launches pending asynchronous calls for the specified required call IDs.
interpreter/frame.go:408
↓ 9 callers
Function
EnvironmentFile
EnvironmentFile returns an EnvOption which loads a serialized CEL environment from a file. The file must be in one of the following formats: - Textpro
tools/compiler/compiler.go:224
↓ 9 callers
Function
EquivExpr
EquivExpr determines whether two expressions are structurally equivalent. The comparison ignores numeric IDs except for resolving references and type
common/ast/equiv.go:128
↓ 9 callers
Method
FindStructFieldNames
FindStructFieldNames returns the field names associated with the type, if the type is found.
common/types/provider.go:64
↓ 9 callers
Method
HasBinding
HasBinding indicates whether the overload already has a definition.
common/decls/decls.go:825
↓ 9 callers
Method
IsChecked
IsChecked returns whether the Ast value has been successfully type-checked.
cel/env.go:80
↓ 9 callers
Function
ListsVersion
ListsVersion configures the version of the string library. The version limits which functions are available. Only functions introduced below or equal
ext/lists.go:258
↓ 9 callers
Function
Math
Math returns a cel.EnvOption to configure namespaced math helper macros and functions. Note, all macros use the 'math' namespace; however, at the tim
ext/math.go:346
↓ 9 callers
Function
NewCatalog
NewCatalog creates a new Catalog initialized with the given symbols.
common/env/catalog.go:59
↓ 9 callers
Function
NewContextVariable
NewContextVariable returns a serializable context variable with a specific type name.
common/env/env.go:317
↓ 9 callers
Function
NewDispatcher
NewDispatcher returns an empty Dispatcher instance.
interpreter/dispatcher.go:36
↓ 9 callers
Method
NewError
NewError associates an error message with a given expression id.
cel/macro.go:142
↓ 9 callers
Function
NewExtension
NewExtension creates a serializable Extension from a name and version string.
common/env/env.go:475
↓ 9 callers
Function
NewInterpreter
NewInterpreter builds an Interpreter from a Dispatcher and TypeProvider which will be used throughout the Eval of all Interpretable instances generate
interpreter/interpreter.go:251
↓ 9 callers
Method
NewMap
NewMap creates an Expr value representing a map literal expression
common/ast/factory.go:58
↓ 9 callers
Method
NewMemberCall
NewMemberCall creates a function call Expr value for a receiver-style function.
parser/macro.go:282
↓ 9 callers
Function
NewMemoryTracker
NewMemoryTracker returns a new MemoryTracker configured with optional MemoryTrackerOption settings, using a default SizeCalculator when one is not pro
common/types/memory_tracker.go:88
↓ 9 callers
Function
NewParser
NewParser creates a new Parser object with a set of functional options.
policy/parser.go:556
↓ 9 callers
Method
NewPresenceTest
NewPresenceTest creates an Expr representing a field presence test on an operand expression.
common/ast/factory.go:65
↓ 9 callers
Method
NewString
NewString creates a new ValueString from the YAML node.
policy/parser.go:449
↓ 9 callers
Method
NewUnspecifiedExpr
NewUnspecifiedExpr creates an empty expression node.
common/ast/factory.go:79
↓ 9 callers
Function
OverloadCostEstimate
OverloadCostEstimate binds a FunctionEstimator to a specific function overload ID. When an OverloadCostEstimate is provided, it overrides the cost ca
common/cost/estimator.go:138
↓ 9 callers
Method
Parent
Parent returns the parent of the current activation, may be nil. If non-nil, the parent will be searched during resolve calls.
interpreter/activation.go:35
↓ 9 callers
Method
Receive
Receive accepts a function name, overload id, and arguments and returns a value.
common/types/traits/receiver.go:23
↓ 9 callers
Function
ReceiverMacro
ReceiverMacro creates a Macro for a receiver function matching the specified arg count.
cel/macro.go:165
↓ 9 callers
Method
RegisterDescriptor
RegisterDescriptor registers the contents of a protocol buffer `FileDescriptor`.
common/types/ref/provider.go:70
↓ 9 callers
Method
RelativeAttribute
RelativeAttribute creates an attribute whose value is a qualification of a dynamic computation rather than a static variable reference.
interpreter/attributes.go:53
← previous
next →
401–500 of 9,178, ranked by callers