Class SimpleTest

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
dev.cel.expr.conformance.test.SimpleTest
All Implemented Interfaces:
com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, SimpleTestOrBuilder, Serializable

public final class SimpleTest extends com.google.protobuf.GeneratedMessageV3 implements SimpleTestOrBuilder
 A test which should run the given CEL program through parsing,
 optionally through checking, then evaluation, with the results
 of the pipeline validated by the given result matcher.
 
Protobuf type cel.expr.conformance.test.SimpleTest
See Also:
  • Field Details

  • Method Details

    • newInstance

      protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
      Overrides:
      newInstance in class com.google.protobuf.GeneratedMessageV3
    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
      Overrides:
      internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessageV3
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
    • getResultMatcherCase

      public SimpleTest.ResultMatcherCase getResultMatcherCase()
      Specified by:
      getResultMatcherCase in interface SimpleTestOrBuilder
    • getName

      public String getName()
       Required.  The name of the test, which should be unique in the test file.
       
      string name = 1;
      Specified by:
      getName in interface SimpleTestOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Required.  The name of the test, which should be unique in the test file.
       
      string name = 1;
      Specified by:
      getNameBytes in interface SimpleTestOrBuilder
      Returns:
      The bytes for name.
    • getDescription

      public String getDescription()
       A description of the test.
       
      string description = 2;
      Specified by:
      getDescription in interface SimpleTestOrBuilder
      Returns:
      The description.
    • getDescriptionBytes

      public com.google.protobuf.ByteString getDescriptionBytes()
       A description of the test.
       
      string description = 2;
      Specified by:
      getDescriptionBytes in interface SimpleTestOrBuilder
      Returns:
      The bytes for description.
    • getExpr

      public String getExpr()
       Required.  The text of the CEL expression.
       
      string expr = 3;
      Specified by:
      getExpr in interface SimpleTestOrBuilder
      Returns:
      The expr.
    • getExprBytes

      public com.google.protobuf.ByteString getExprBytes()
       Required.  The text of the CEL expression.
       
      string expr = 3;
      Specified by:
      getExprBytes in interface SimpleTestOrBuilder
      Returns:
      The bytes for expr.
    • getDisableMacros

      public boolean getDisableMacros()
       Disables all macro expansion in parsing.
       
      bool disable_macros = 4;
      Specified by:
      getDisableMacros in interface SimpleTestOrBuilder
      Returns:
      The disableMacros.
    • getDisableCheck

      public boolean getDisableCheck()
       Disables the check phase.
       
      bool disable_check = 5;
      Specified by:
      getDisableCheck in interface SimpleTestOrBuilder
      Returns:
      The disableCheck.
    • getCheckOnly

      public boolean getCheckOnly()
       Disables the evaluate phase.
       
      bool check_only = 15;
      Specified by:
      getCheckOnly in interface SimpleTestOrBuilder
      Returns:
      The checkOnly.
    • getTypeEnvList

      public List<Decl> getTypeEnvList()
       The type environment to use for the check phase.
       
      repeated .cel.expr.Decl type_env = 6;
      Specified by:
      getTypeEnvList in interface SimpleTestOrBuilder
    • getTypeEnvOrBuilderList

      public List<? extends DeclOrBuilder> getTypeEnvOrBuilderList()
       The type environment to use for the check phase.
       
      repeated .cel.expr.Decl type_env = 6;
      Specified by:
      getTypeEnvOrBuilderList in interface SimpleTestOrBuilder
    • getTypeEnvCount

      public int getTypeEnvCount()
       The type environment to use for the check phase.
       
      repeated .cel.expr.Decl type_env = 6;
      Specified by:
      getTypeEnvCount in interface SimpleTestOrBuilder
    • getTypeEnv

      public Decl getTypeEnv(int index)
       The type environment to use for the check phase.
       
      repeated .cel.expr.Decl type_env = 6;
      Specified by:
      getTypeEnv in interface SimpleTestOrBuilder
    • getTypeEnvOrBuilder

      public DeclOrBuilder getTypeEnvOrBuilder(int index)
       The type environment to use for the check phase.
       
      repeated .cel.expr.Decl type_env = 6;
      Specified by:
      getTypeEnvOrBuilder in interface SimpleTestOrBuilder
    • getContainer

      public String getContainer()
       The container for name resolution.
       
      string container = 13;
      Specified by:
      getContainer in interface SimpleTestOrBuilder
      Returns:
      The container.
    • getContainerBytes

      public com.google.protobuf.ByteString getContainerBytes()
       The container for name resolution.
       
      string container = 13;
      Specified by:
      getContainerBytes in interface SimpleTestOrBuilder
      Returns:
      The bytes for container.
    • getLocale

      public String getLocale()
       The locale to use for the evaluation phase.
       
      string locale = 14;
      Specified by:
      getLocale in interface SimpleTestOrBuilder
      Returns:
      The locale.
    • getLocaleBytes

      public com.google.protobuf.ByteString getLocaleBytes()
       The locale to use for the evaluation phase.
       
      string locale = 14;
      Specified by:
      getLocaleBytes in interface SimpleTestOrBuilder
      Returns:
      The bytes for locale.
    • getBindingsCount

      public int getBindingsCount()
      Description copied from interface: SimpleTestOrBuilder
       Variable bindings to use for the eval phase.
       
      map<string, .cel.expr.ExprValue> bindings = 7;
      Specified by:
      getBindingsCount in interface SimpleTestOrBuilder
    • containsBindings

      public boolean containsBindings(String key)
       Variable bindings to use for the eval phase.
       
      map<string, .cel.expr.ExprValue> bindings = 7;
      Specified by:
      containsBindings in interface SimpleTestOrBuilder
    • getBindings

      @Deprecated public Map<String,ExprValue> getBindings()
      Deprecated.
      Use getBindingsMap() instead.
      Specified by:
      getBindings in interface SimpleTestOrBuilder
    • getBindingsMap

      public Map<String,ExprValue> getBindingsMap()
       Variable bindings to use for the eval phase.
       
      map<string, .cel.expr.ExprValue> bindings = 7;
      Specified by:
      getBindingsMap in interface SimpleTestOrBuilder
    • getBindingsOrDefault

      public ExprValue getBindingsOrDefault(String key, ExprValue defaultValue)
       Variable bindings to use for the eval phase.
       
      map<string, .cel.expr.ExprValue> bindings = 7;
      Specified by:
      getBindingsOrDefault in interface SimpleTestOrBuilder
    • getBindingsOrThrow

      public ExprValue getBindingsOrThrow(String key)
       Variable bindings to use for the eval phase.
       
      map<string, .cel.expr.ExprValue> bindings = 7;
      Specified by:
      getBindingsOrThrow in interface SimpleTestOrBuilder
    • hasValue

      public boolean hasValue()
       A normal value, which must match the evaluation result exactly
       via value equality semantics.  This coincides with proto equality,
       except for:
       *   maps are order-agnostic.
       *   a floating point NaN should match any NaN.
       
      .cel.expr.Value value = 8;
      Specified by:
      hasValue in interface SimpleTestOrBuilder
      Returns:
      Whether the value field is set.
    • getValue

      public Value getValue()
       A normal value, which must match the evaluation result exactly
       via value equality semantics.  This coincides with proto equality,
       except for:
       *   maps are order-agnostic.
       *   a floating point NaN should match any NaN.
       
      .cel.expr.Value value = 8;
      Specified by:
      getValue in interface SimpleTestOrBuilder
      Returns:
      The value.
    • getValueOrBuilder

      public ValueOrBuilder getValueOrBuilder()
       A normal value, which must match the evaluation result exactly
       via value equality semantics.  This coincides with proto equality,
       except for:
       *   maps are order-agnostic.
       *   a floating point NaN should match any NaN.
       
      .cel.expr.Value value = 8;
      Specified by:
      getValueOrBuilder in interface SimpleTestOrBuilder
    • hasTypedResult

      public boolean hasTypedResult()
       A result and deduced expression type.
       
      .cel.expr.conformance.test.TypedResult typed_result = 16;
      Specified by:
      hasTypedResult in interface SimpleTestOrBuilder
      Returns:
      Whether the typedResult field is set.
    • getTypedResult

      public TypedResult getTypedResult()
       A result and deduced expression type.
       
      .cel.expr.conformance.test.TypedResult typed_result = 16;
      Specified by:
      getTypedResult in interface SimpleTestOrBuilder
      Returns:
      The typedResult.
    • getTypedResultOrBuilder

      public TypedResultOrBuilder getTypedResultOrBuilder()
       A result and deduced expression type.
       
      .cel.expr.conformance.test.TypedResult typed_result = 16;
      Specified by:
      getTypedResultOrBuilder in interface SimpleTestOrBuilder
    • hasEvalError

      public boolean hasEvalError()
       Matches error evaluation results.
       
      .cel.expr.ErrorSet eval_error = 9;
      Specified by:
      hasEvalError in interface SimpleTestOrBuilder
      Returns:
      Whether the evalError field is set.
    • getEvalError

      public ErrorSet getEvalError()
       Matches error evaluation results.
       
      .cel.expr.ErrorSet eval_error = 9;
      Specified by:
      getEvalError in interface SimpleTestOrBuilder
      Returns:
      The evalError.
    • getEvalErrorOrBuilder

      public ErrorSetOrBuilder getEvalErrorOrBuilder()
       Matches error evaluation results.
       
      .cel.expr.ErrorSet eval_error = 9;
      Specified by:
      getEvalErrorOrBuilder in interface SimpleTestOrBuilder
    • hasAnyEvalErrors

      public boolean hasAnyEvalErrors()
       Matches one of several error results.
       (Using explicit message since oneof can't handle repeated.)
       
      .cel.expr.conformance.test.ErrorSetMatcher any_eval_errors = 10;
      Specified by:
      hasAnyEvalErrors in interface SimpleTestOrBuilder
      Returns:
      Whether the anyEvalErrors field is set.
    • getAnyEvalErrors

      public ErrorSetMatcher getAnyEvalErrors()
       Matches one of several error results.
       (Using explicit message since oneof can't handle repeated.)
       
      .cel.expr.conformance.test.ErrorSetMatcher any_eval_errors = 10;
      Specified by:
      getAnyEvalErrors in interface SimpleTestOrBuilder
      Returns:
      The anyEvalErrors.
    • getAnyEvalErrorsOrBuilder

      public ErrorSetMatcherOrBuilder getAnyEvalErrorsOrBuilder()
       Matches one of several error results.
       (Using explicit message since oneof can't handle repeated.)
       
      .cel.expr.conformance.test.ErrorSetMatcher any_eval_errors = 10;
      Specified by:
      getAnyEvalErrorsOrBuilder in interface SimpleTestOrBuilder
    • hasUnknown

      public boolean hasUnknown()
       Matches unknown evaluation results.
       
      .cel.expr.UnknownSet unknown = 11;
      Specified by:
      hasUnknown in interface SimpleTestOrBuilder
      Returns:
      Whether the unknown field is set.
    • getUnknown

      public UnknownSet getUnknown()
       Matches unknown evaluation results.
       
      .cel.expr.UnknownSet unknown = 11;
      Specified by:
      getUnknown in interface SimpleTestOrBuilder
      Returns:
      The unknown.
    • getUnknownOrBuilder

      public UnknownSetOrBuilder getUnknownOrBuilder()
       Matches unknown evaluation results.
       
      .cel.expr.UnknownSet unknown = 11;
      Specified by:
      getUnknownOrBuilder in interface SimpleTestOrBuilder
    • hasAnyUnknowns

      public boolean hasAnyUnknowns()
       Matches one of several unknown results.
       (Using explicit message since oneof can't handle repeated.)
       
      .cel.expr.conformance.test.UnknownSetMatcher any_unknowns = 12;
      Specified by:
      hasAnyUnknowns in interface SimpleTestOrBuilder
      Returns:
      Whether the anyUnknowns field is set.
    • getAnyUnknowns

      public UnknownSetMatcher getAnyUnknowns()
       Matches one of several unknown results.
       (Using explicit message since oneof can't handle repeated.)
       
      .cel.expr.conformance.test.UnknownSetMatcher any_unknowns = 12;
      Specified by:
      getAnyUnknowns in interface SimpleTestOrBuilder
      Returns:
      The anyUnknowns.
    • getAnyUnknownsOrBuilder

      public UnknownSetMatcherOrBuilder getAnyUnknownsOrBuilder()
       Matches one of several unknown results.
       (Using explicit message since oneof can't handle repeated.)
       
      .cel.expr.conformance.test.UnknownSetMatcher any_unknowns = 12;
      Specified by:
      getAnyUnknownsOrBuilder in interface SimpleTestOrBuilder
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessageV3
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessageV3
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static SimpleTest parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static SimpleTest parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static SimpleTest parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static SimpleTest parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static SimpleTest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static SimpleTest parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static SimpleTest parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static SimpleTest parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static SimpleTest parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static SimpleTest parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static SimpleTest parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static SimpleTest parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public SimpleTest.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static SimpleTest.Builder newBuilder()
    • newBuilder

      public static SimpleTest.Builder newBuilder(SimpleTest prototype)
    • toBuilder

      public SimpleTest.Builder toBuilder()
      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected SimpleTest.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
      Specified by:
      newBuilderForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstance

      public static SimpleTest getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<SimpleTest> parser()
    • getParserForType

      public com.google.protobuf.Parser<SimpleTest> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstanceForType

      public SimpleTest getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder