Package cel.dev.expr.conformance
Interface EnvironmentOrBuilder
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
Environment,Environment.Builder
public interface EnvironmentOrBuilder
extends com.google.protobuf.MessageOrBuilder
-
Method Summary
Modifier and TypeMethodDescriptionSets the namespace (container) for the expression.com.google.protobuf.ByteStringSets the namespace (container) for the expression.If set, adds a context declaration from a proto message.If set, adds a context declaration from a proto message.getDeclarations(int index) List of declarations to be configured in the CEL environment.intList of declarations to be configured in the CEL environment.List of declarations to be configured in the CEL environment.getDeclarationsOrBuilder(int index) List of declarations to be configured in the CEL environment.List<? extends DeclOrBuilder>List of declarations to be configured in the CEL environment.Description for the current environmentcom.google.protobuf.ByteStringDescription for the current environmentbooleanDisables including the declarations from the standard CEL environment.booleanWhen macro call tracking is enabled, the resulting SourceInfo in the CheckedExpr will contain a collection of expressions representing the function calls which were replaced by macros.getExtensions(int index) List of extensions to enable in the CEL environment.intList of extensions to enable in the CEL environment.List of extensions to enable in the CEL environment.getExtensionsOrBuilder(int index) List of extensions to enable in the CEL environment.List<? extends ExtensionOrBuilder>List of extensions to enable in the CEL environment.getFeatures(int index) List of feature flags to be enabled or disabled.intList of feature flags to be enabled or disabled.List of feature flags to be enabled or disabled.getFeaturesOrBuilder(int index) List of feature flags to be enabled or disabled.List<? extends FeatureOrBuilder>List of feature flags to be enabled or disabled.getImports(int index) List of abbreviations to be added to the CEL environmentintList of abbreviations to be added to the CEL environmentList of abbreviations to be added to the CEL environmentgetImportsOrBuilder(int index) List of abbreviations to be added to the CEL environmentList<? extends Environment.ImportOrBuilder>List of abbreviations to be added to the CEL environmentcom.google.protobuf.DescriptorProtos.FileDescriptorSetIf provided, uses the provided FileDescriptorSet to extend types available the CEL expression.com.google.protobuf.DescriptorProtos.FileDescriptorSetOrBuilderIf provided, uses the provided FileDescriptorSet to extend types available the CEL expression.getName()Name of the environmentcom.google.protobuf.ByteStringName of the environmentSet of options to subset a subsettable librarySet of options to subset a subsettable librarygetValidators(int index) List of validators for validating the parsed ast.intList of validators for validating the parsed ast.List of validators for validating the parsed ast.getValidatorsOrBuilder(int index) List of validators for validating the parsed ast.List<? extends ValidatorOrBuilder>List of validators for validating the parsed ast.booleanIf set, adds a context declaration from a proto message.booleanIf provided, uses the provided FileDescriptorSet to extend types available the CEL expression.booleanSet of options to subset a subsettable libraryMethods inherited from interface com.google.protobuf.MessageLiteOrBuilder
isInitializedMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getName
String getName()Name of the environment
string name = 1;- Returns:
- The name.
-
getNameBytes
com.google.protobuf.ByteString getNameBytes()Name of the environment
string name = 1;- Returns:
- The bytes for name.
-
getDescription
String getDescription()Description for the current environment
string description = 2;- Returns:
- The description.
-
getDescriptionBytes
com.google.protobuf.ByteString getDescriptionBytes()Description for the current environment
string description = 2;- Returns:
- The bytes for description.
-
getContainer
String getContainer()Sets the namespace (container) for the expression. This is used to simplify resolution. For example with container `google.rpc.context` an identifier of `google.rpc.context.AttributeContext` could be referred to simply as `AttributeContext` in the CEL expression.
string container = 3;- Returns:
- The container.
-
getContainerBytes
com.google.protobuf.ByteString getContainerBytes()Sets the namespace (container) for the expression. This is used to simplify resolution. For example with container `google.rpc.context` an identifier of `google.rpc.context.AttributeContext` could be referred to simply as `AttributeContext` in the CEL expression.
string container = 3;- Returns:
- The bytes for container.
-
getImportsList
List<Environment.Import> getImportsList()List of abbreviations to be added to the CEL environment
repeated .cel.expr.conformance.Environment.Import imports = 4; -
getImports
List of abbreviations to be added to the CEL environment
repeated .cel.expr.conformance.Environment.Import imports = 4; -
getImportsCount
int getImportsCount()List of abbreviations to be added to the CEL environment
repeated .cel.expr.conformance.Environment.Import imports = 4; -
getImportsOrBuilderList
List<? extends Environment.ImportOrBuilder> getImportsOrBuilderList()List of abbreviations to be added to the CEL environment
repeated .cel.expr.conformance.Environment.Import imports = 4; -
getImportsOrBuilder
List of abbreviations to be added to the CEL environment
repeated .cel.expr.conformance.Environment.Import imports = 4; -
hasStdlib
boolean hasStdlib()Set of options to subset a subsettable library
.cel.expr.conformance.LibrarySubset stdlib = 5;- Returns:
- Whether the stdlib field is set.
-
getStdlib
LibrarySubset getStdlib()Set of options to subset a subsettable library
.cel.expr.conformance.LibrarySubset stdlib = 5;- Returns:
- The stdlib.
-
getStdlibOrBuilder
LibrarySubsetOrBuilder getStdlibOrBuilder()Set of options to subset a subsettable library
.cel.expr.conformance.LibrarySubset stdlib = 5; -
getExtensionsList
List of extensions to enable in the CEL environment.
repeated .cel.expr.conformance.Extension extensions = 6; -
getExtensions
List of extensions to enable in the CEL environment.
repeated .cel.expr.conformance.Extension extensions = 6; -
getExtensionsCount
int getExtensionsCount()List of extensions to enable in the CEL environment.
repeated .cel.expr.conformance.Extension extensions = 6; -
getExtensionsOrBuilderList
List<? extends ExtensionOrBuilder> getExtensionsOrBuilderList()List of extensions to enable in the CEL environment.
repeated .cel.expr.conformance.Extension extensions = 6; -
getExtensionsOrBuilder
List of extensions to enable in the CEL environment.
repeated .cel.expr.conformance.Extension extensions = 6; -
hasContextVariable
boolean hasContextVariable()If set, adds a context declaration from a proto message. Context messages have all of their top-level fields available as variables in the type checker.
.cel.expr.conformance.Environment.ContextVariable context_variable = 7;- Returns:
- Whether the contextVariable field is set.
-
getContextVariable
Environment.ContextVariable getContextVariable()If set, adds a context declaration from a proto message. Context messages have all of their top-level fields available as variables in the type checker.
.cel.expr.conformance.Environment.ContextVariable context_variable = 7;- Returns:
- The contextVariable.
-
getContextVariableOrBuilder
Environment.ContextVariableOrBuilder getContextVariableOrBuilder()If set, adds a context declaration from a proto message. Context messages have all of their top-level fields available as variables in the type checker.
.cel.expr.conformance.Environment.ContextVariable context_variable = 7; -
getDeclarationsList
List of declarations to be configured in the CEL environment. Note: The CEL environment can be configured with either the context_variable or a set of ident_decls provided as part of declarations. Providing both will result in an error.
repeated .cel.expr.Decl declarations = 8; -
getDeclarations
List of declarations to be configured in the CEL environment. Note: The CEL environment can be configured with either the context_variable or a set of ident_decls provided as part of declarations. Providing both will result in an error.
repeated .cel.expr.Decl declarations = 8; -
getDeclarationsCount
int getDeclarationsCount()List of declarations to be configured in the CEL environment. Note: The CEL environment can be configured with either the context_variable or a set of ident_decls provided as part of declarations. Providing both will result in an error.
repeated .cel.expr.Decl declarations = 8; -
getDeclarationsOrBuilderList
List<? extends DeclOrBuilder> getDeclarationsOrBuilderList()List of declarations to be configured in the CEL environment. Note: The CEL environment can be configured with either the context_variable or a set of ident_decls provided as part of declarations. Providing both will result in an error.
repeated .cel.expr.Decl declarations = 8; -
getDeclarationsOrBuilder
List of declarations to be configured in the CEL environment. Note: The CEL environment can be configured with either the context_variable or a set of ident_decls provided as part of declarations. Providing both will result in an error.
repeated .cel.expr.Decl declarations = 8; -
getValidatorsList
List of validators for validating the parsed ast.
repeated .cel.expr.conformance.Validator validators = 9; -
getValidators
List of validators for validating the parsed ast.
repeated .cel.expr.conformance.Validator validators = 9; -
getValidatorsCount
int getValidatorsCount()List of validators for validating the parsed ast.
repeated .cel.expr.conformance.Validator validators = 9; -
getValidatorsOrBuilderList
List<? extends ValidatorOrBuilder> getValidatorsOrBuilderList()List of validators for validating the parsed ast.
repeated .cel.expr.conformance.Validator validators = 9; -
getValidatorsOrBuilder
List of validators for validating the parsed ast.
repeated .cel.expr.conformance.Validator validators = 9; -
getFeaturesList
List of feature flags to be enabled or disabled.
repeated .cel.expr.conformance.Feature features = 10; -
getFeatures
List of feature flags to be enabled or disabled.
repeated .cel.expr.conformance.Feature features = 10; -
getFeaturesCount
int getFeaturesCount()List of feature flags to be enabled or disabled.
repeated .cel.expr.conformance.Feature features = 10; -
getFeaturesOrBuilderList
List<? extends FeatureOrBuilder> getFeaturesOrBuilderList()List of feature flags to be enabled or disabled.
repeated .cel.expr.conformance.Feature features = 10; -
getFeaturesOrBuilder
List of feature flags to be enabled or disabled.
repeated .cel.expr.conformance.Feature features = 10; -
getDisableStandardCelDeclarations
boolean getDisableStandardCelDeclarations()Disables including the declarations from the standard CEL environment. NOTE: Do not disable the standard CEL declarations unless you are aware of the implications and have discussed your use case on cel-discuss@ or with the members of the cel-governance-team@ Deprecated: Use LibrarySubset to disable standard cel declarations instead: stdlib = LibrarySubset{ disable: true }bool disable_standard_cel_declarations = 11;- Returns:
- The disableStandardCelDeclarations.
-
hasMessageTypeExtension
boolean hasMessageTypeExtension()If provided, uses the provided FileDescriptorSet to extend types available the CEL expression. All "well-known" protobuf messages (google.protobuf.*) are known to the CEL compiler, but all others must be provided for type checking.
.google.protobuf.FileDescriptorSet message_type_extension = 12;- Returns:
- Whether the messageTypeExtension field is set.
-
getMessageTypeExtension
com.google.protobuf.DescriptorProtos.FileDescriptorSet getMessageTypeExtension()If provided, uses the provided FileDescriptorSet to extend types available the CEL expression. All "well-known" protobuf messages (google.protobuf.*) are known to the CEL compiler, but all others must be provided for type checking.
.google.protobuf.FileDescriptorSet message_type_extension = 12;- Returns:
- The messageTypeExtension.
-
getMessageTypeExtensionOrBuilder
com.google.protobuf.DescriptorProtos.FileDescriptorSetOrBuilder getMessageTypeExtensionOrBuilder()If provided, uses the provided FileDescriptorSet to extend types available the CEL expression. All "well-known" protobuf messages (google.protobuf.*) are known to the CEL compiler, but all others must be provided for type checking.
.google.protobuf.FileDescriptorSet message_type_extension = 12; -
getEnableMacroCallTracking
boolean getEnableMacroCallTracking()When macro call tracking is enabled, the resulting SourceInfo in the CheckedExpr will contain a collection of expressions representing the function calls which were replaced by macros. Deprecated: Use Feature to enable macro call tracking Feature{ name: "cel.feature.macro_call_tracking", enabled: true }bool enable_macro_call_tracking = 13;- Returns:
- The enableMacroCallTracking.
-