MCPcopy Create free account

hub / github.com/cel-expr/cel-go / functions

Functions7,701 in github.com/cel-expr/cel-go

↓ 285 callersMethodError
()
common/runes/buffer.go:123
↓ 242 callersMethodErr
Err returns an error value if the issues list contains one or more errors.
cel/env.go:1084
↓ 232 callersMethodEqual
Equal returns true if the `other` value has the same type and content as the implementing struct.
common/types/ref/reference.go:55
↓ 201 callersMethodKind
Kind of the expression node. See ExprKind for the valid enum values.
common/ast/expr.go:62
↓ 181 callersMethodContains
Contains returns true if the value exists within the object.
common/types/traits/container.go:22
↓ 179 callersMethodEval
Eval returns the result of an evaluation of the Ast and environment against the input vars. The vars value may either be an `Activation` or a `map[st
cel/program.go:48
↓ 165 callersMethodID
ID of the expression as it appears in the AST
common/ast/expr.go:59
↓ 155 callersFunctionNewEnv
NewEnv creates a program environment configured with the standard library of CEL functions and macros. The Env value returned can parse and check any
cel/env.go:361
↓ 154 callersFunctionVariable
Variable creates an instance of a variable declaration with a variable name and type.
cel/decls.go:144
↓ 152 callersMethodProgram
Program generates an evaluable instance of the Ast within the environment (Env).
cel/env.go:723
↓ 145 callersFunctionIsError
IsError returns whether the input element ref.Type or ref.Val is equal to the ErrType singleton.
common/types/err.go:171
↓ 134 callersMethodNew
New returns a mutable proto message
common/types/pb/type.go:144
↓ 122 callersMethodValue
Value returns the map entry value expression.
common/ast/expr.go:230
↓ 121 callersMethodConvertToNative
ConvertToNative converts the Value to a native Go struct according to the reflected type description, or error if the conversion is not feasible. The
common/types/ref/reference.go:49
↓ 121 callersMethodNativeToValue
NativeToValue converts the input `value` to a CEL `ref.Val`.
common/types/ref/provider.go:56
↓ 112 callersFunctionnewTestRegistry
(t *testing.T, opts ...RegistryOption)
common/types/provider_test.go:1489
↓ 99 callersMethodCompile
()
repl/parser/commands_parser.go:533
↓ 97 callersFunctionNoVars
NoVars returns an empty Activation.
cel/program.go:101
↓ 86 callersMethodError
()
cel/async/async_test.go:34
↓ 85 callersFunctionNewErr
NewErr creates a new Err described by the format string and args. TODO: Audit the use of this function and standardize the error messages and codes.
common/types/err.go:61
↓ 81 callersMethodAdd
Add returns a combination of the current value and other value. If the other value is an unsupported type, an error is returned.
common/types/traits/math.go:24
↓ 81 callersMethodString
String takes a ref.Val and a string representing the current locale identifier and returns the Val formatted as a string, or an error if one occurred.
ext/formatting.go:742
↓ 77 callersMethodTypeName
TypeName returns the struct type name.
common/ast/expr.go:242
↓ 69 callersMethodAsCall
AsCall adapts the expr into a CallExpr The Kind() must be equal to a CallKind for the conversion to be well-defined.
common/ast/expr.go:67
↓ 69 callersFunctionFunction
Function defines a function and overloads with optional singleton or per-overload bindings. Using Function is roughly equivalent to calling Declarati
cel/decls.go:195
↓ 66 callersMethodError
Error implements error.
ext/formatting.go:708
↓ 63 callersMethodType
Type returns the deduced type of the AstNode.
checker/cost.go:64
↓ 63 callersFunctiontestEnv
(t testing.TB, opts ...EnvOption)
cel/cel_test.go:4379
↓ 61 callersMethodCompile
Compile combines the Parse and Check phases CEL program compilation to produce an Ast and associated issues. If an error is encountered during parsin
cel/env.go:499
↓ 60 callersMethodParse
()
repl/parser/commands_parser.go:534
↓ 59 callersMethodReportError
ReportError records an error at a source location.
common/errors.go:45
↓ 58 callersMethodGet
Get the value at the specified index or error.
common/types/traits/indexer.go:24
↓ 56 callersMethodName
Name returns the name of the field.
common/ast/expr.go:254
↓ 55 callersMethodGetState
GetState retrieves the stateful metadata from the execution frame.
interpreter/interpreter.go:50
↓ 54 callersMethodRecover
(recognizer antlr.Parser, e antlr.RecognitionException)
parser/parser.go:294
↓ 53 callersMethodExpr
Expr returns the expression of the AstNode.
checker/cost.go:67
↓ 53 callersFunctionMaybeNoSuchOverloadErr
MaybeNoSuchOverloadErr returns the error or unknown if the input ref.Val is one of these types, else a new no such overload error.
common/types/err.go:101
↓ 53 callersFunctionOverload
Overload defines a new global overload with an overload id, argument types, and result type. Through the use of OverloadOpt options, the overload may
cel/decls.go:307
↓ 50 callersFunctionProtoTypeDefs
ProtoTypeDefs creates a RegistryOption which registers the individual proto messages with the registry.
common/types/provider.go:128
↓ 49 callersMethodAsLiteral
AsLiteral adapts the expr into a constant ref.Val. The Kind() must be equal to a LiteralKind for the conversion to be well-defined.
common/ast/expr.go:82
↓ 49 callersFunctionNewFunction
NewFunction creates a new function declaration with a set of function options to configure overloads and function definitions (implementations). Func
common/decls/decls.go:37
↓ 48 callersMethodID
ID where the qualifier appears within an expression.
interpreter/attributes.go:69
↓ 48 callersMethodMatch
Match returns true if the pattern matches the current value.
common/types/traits/matcher.go:22
↓ 47 callersMethodExtend
Extend the current environment with additional options to produce a new Env. Note, the extended Env value should not share memory with the original.
cel/env.go:534
↓ 47 callersFunctionNewCustomEnv
NewCustomEnv creates a custom program environment which is not automatically configured with the standard library of functions and macros documented i
cel/env.go:384
↓ 47 callersFunctionWrapErr
WrapErr wraps an existing Go error value into a CEL Err value.
common/types/err.go:115
↓ 46 callersMethodArgs
Args returns the list of call arguments, excluding the target.
common/ast/expr.go:173
↓ 46 callersMethodCheck
Check performs type-checking on the input Ast and yields a checked Ast and/or set of Issues. If any `ASTValidators` are configured on the environment,
cel/env.go:417
↓ 46 callersMethodDescriptor
Descriptor returns the protoreflect.FieldDescriptor for this type.
common/types/pb/type.go:243
↓ 46 callersMethodGet
(i int)
common/runes/buffer.go:26
↓ 45 callersFunctionEvalOptions
EvalOptions sets one or more evaluation options which may affect the evaluation or Result.
cel/options.go:735
↓ 45 callersFunctionOverload
Overload defines a new global overload with an overload id, argument types, and result type. Through the use of OverloadOpt options, the overload may
common/decls/decls.go:589
↓ 43 callersMethodFunctionName
FunctionName returns the name of the function.
common/ast/expr.go:164
↓ 43 callersFunctionOptionalTypes
OptionalTypes enable support for optional syntax and types in CEL. The optional value type makes it possible to express whether variables have been p
cel/library.go:366
↓ 43 callersMethodReportErrorAtID
ReportErrorAtID logs an error during parsing which is included in the issue set returned from a failed parse.
policy/parser.go:423
↓ 42 callersMethodAsIdent
AsIdent adapts the expr into an identifier string. The Kind() must be equal to an IdentKind for the conversion to be well-defined.
common/ast/expr.go:77
↓ 42 callersMethodLen
()
common/runes/buffer.go:28
↓ 42 callersFunctionNewActivation
NewActivation returns an activation based on a map-based binding where the map keys are expected to be qualified names used with ResolveName calls. T
interpreter/activation.go:61
↓ 40 callersMethodAsList
AsList adapts the expr into a ListExpr. The Kind() must be equal to a ListKind for the conversion to be well-defined.
common/ast/expr.go:87
↓ 40 callersMethodNewLiteral
NewLiteral creates an Expr value representing a literal value, such as a string or integer.
common/ast/factory.go:50
↓ 40 callersFunctionnewTestRegistry
(t testing.TB, opts ...types.RegistryOption)
interpreter/interpreter_test.go:2640
↓ 39 callersFunctionTypes
Types adds one or more type declarations to the environment, allowing for construction of type-literals whose definitions are included in the common e
cel/options.go:348
↓ 38 callersFunctionEmptyActivation
EmptyActivation returns a variable-free activation.
interpreter/activation.go:38
↓ 38 callersMethodExec
Exec evaluates the expression within the given ExecutionFrame.
interpreter/interpretable.go:46
↓ 38 callersMethodSize
Size returns the number of entries in the map.
common/ast/expr.go:218
↓ 38 callersMethodType
Type returns the TypeValue of the value.
common/types/ref/reference.go:58
↓ 37 callersMethodAsComprehension
AsComprehension adapts the expr into a ComprehensionExpr. The Kind() must be equal to a ComprehensionKind for the conversion to be well-defined.
common/ast/expr.go:72
↓ 37 callersMethodLA
LA implements (antlr.CharStream).LA.
parser/input.go:38
↓ 37 callersMethodName
Name returns the name of the validator. Names must be unique.
cel/validator.go:118
↓ 37 callersFunctionNewListType
NewListType creates an instances of a list type value with the provided element type.
common/types/types.go:480
↓ 37 callersFunctionNewObjectType
NewObjectType creates a type reference to an externally defined type, e.g. a protobuf message type. An object type is assumed to support field presen
common/types/types.go:542
↓ 37 callersFunctionNewRegistry
NewRegistry accepts a list of proto message instances, ref.Type instances, or RegistryOption functions and returns a type provider.
common/types/provider.go:105
↓ 37 callersFunctionNewTypeParamType
NewTypeParamType creates a parameterized type instance.
common/types/types.go:584
↓ 37 callersMethodValue
Value returns the raw value of the instance which may not be directly compatible with the expression language types.
common/types/ref/reference.go:62
↓ 36 callersFunctionNewAttributeFactory
NewAttributeFactory returns a default AttributeFactory which is produces Attribute values capable of resolving types by simple names and qualify the v
interpreter/attributes.go:144
↓ 36 callersFunctionNewExprFactory
NewExprFactory creates an ExprFactory instance.
common/ast/factory.go:89
↓ 35 callersMethodAsSelect
AsSelect adapts the expr into a SelectExpr. The Kind() must be equal to a SelectKind for the conversion to be well-defined.
common/ast/expr.go:97
↓ 34 callersFunctionCompile
Compile is a convenience function that constructs a new Env using the provided EnvOption values, compiles the expression string, and plans an executab
cel/cel.go:26
↓ 34 callersMethodConvertToType
ConvertToType supports type conversions between CEL value types supported by the expression language.
common/types/ref/reference.go:52
↓ 34 callersMethodEnterRule
(listener antlr.ParseTreeListener)
repl/parser/commands_parser.go:1088
↓ 34 callersMethodExitRule
(listener antlr.ParseTreeListener)
repl/parser/commands_parser.go:1094
↓ 34 callersFunctionIsUnknown
IsUnknown returns whether the element ref.Val is in instance of *types.Unknown
common/types/unknown.go:264
↓ 33 callersFunctionAsFrame
AsFrame promotes an Activation to an ExecutionFrame.
interpreter/interpretable.go:199
↓ 33 callersMethodProtoReflect
()
test/proto2pb/test_all_types.pb.go:763
↓ 32 callersMethodElements
Elements returns the list elements as navigable expressions.
common/ast/expr.go:182
↓ 32 callersMethodGetErrors
GetErrors returns the list of observed errors.
common/errors.go:69
↓ 32 callersMethodIsMemberFunction
IsMemberFunction returns whether the call has a non-nil target indicating it is a member function
common/ast/expr.go:167
↓ 32 callersFunctionNewTextSource
TODO(jimlarson) "Character offsets" should index the code points within the UTF-8 encoded string. It currently indexes bytes. Can be accomplished by
common/source.go:73
↓ 31 callersMethodNativeRep
NativeRep converts the AST to a Go-native representation.
cel/env.go:59
↓ 31 callersMethodNewIdent
NewIdent creates an Expr value representing an identifier.
common/ast/factory.go:40
↓ 31 callersFunctionNewMapType
NewMapType creates an instance of a map type value with the provided key and value types.
common/types/types.go:494
↓ 31 callersMethodNext
Next returns the next element.
common/types/traits/iterator.go:35
↓ 30 callersMethodClose
Close releases the resources held by the execution frame and returns it to the pool.
interpreter/frame.go:117
↓ 30 callersMethodFields
Fields returns the set of field initializers in the struct expression as EntryExpr values.
common/ast/expr.go:245
↓ 30 callersMethodGetValue
GetValue returns the wrapped value contained in the optional.
common/types/optional.go:50
↓ 30 callersMethodNewCall
NewCall creates an Expr value representing a global function call.
common/ast/factory.go:28
↓ 30 callersFunctionNewDynamicList
NewDynamicList returns a traits.Lister with heterogenous elements. value should be an array of "native" types, i.e. any type that NativeToValue() can
common/types/list.go:35
↓ 30 callersMethodOperand
Operand returns the selection operand expression.
common/ast/expr.go:200
↓ 30 callersMethodParameters
Parameters returns the list of type parameters if set. For ListKind, Parameters()[0] represents the list element type For MapKind, Parameters()[0] re
common/types/types.go:343
↓ 29 callersMethodIterator
Iterator returns an Iterator over the map key set.
common/types/map.go:126
next →1–100 of 7,701, ranked by callers