
dev.cel.expr.conformance.test.TestOutput Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: cel/expr/conformance/test/suite.proto
// Protobuf Java Version: 3.25.1
package dev.cel.expr.conformance.test;
/**
*
* Expected result of the test case.
*
*
* Protobuf type {@code cel.expr.conformance.test.TestOutput}
*/
public final class TestOutput extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:cel.expr.conformance.test.TestOutput)
TestOutputOrBuilder {
private static final long serialVersionUID = 0L;
// Use TestOutput.newBuilder() to construct.
private TestOutput(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private TestOutput() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new TestOutput();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return dev.cel.expr.conformance.test.SuiteProto.internal_static_cel_expr_conformance_test_TestOutput_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return dev.cel.expr.conformance.test.SuiteProto.internal_static_cel_expr_conformance_test_TestOutput_fieldAccessorTable
.ensureFieldAccessorsInitialized(
dev.cel.expr.conformance.test.TestOutput.class, dev.cel.expr.conformance.test.TestOutput.Builder.class);
}
private int resultKindCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object resultKind_;
public enum ResultKindCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
RESULT_VALUE(8),
RESULT_EXPR(9),
EVAL_ERROR(10),
UNKNOWN(11),
RESULTKIND_NOT_SET(0);
private final int value;
private ResultKindCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ResultKindCase valueOf(int value) {
return forNumber(value);
}
public static ResultKindCase forNumber(int value) {
switch (value) {
case 8: return RESULT_VALUE;
case 9: return RESULT_EXPR;
case 10: return EVAL_ERROR;
case 11: return UNKNOWN;
case 0: return RESULTKIND_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ResultKindCase
getResultKindCase() {
return ResultKindCase.forNumber(
resultKindCase_);
}
public static final int RESULT_VALUE_FIELD_NUMBER = 8;
/**
*
* 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 result_value = 8;
* @return Whether the resultValue field is set.
*/
@java.lang.Override
public boolean hasResultValue() {
return resultKindCase_ == 8;
}
/**
*
* 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 result_value = 8;
* @return The resultValue.
*/
@java.lang.Override
public dev.cel.expr.Value getResultValue() {
if (resultKindCase_ == 8) {
return (dev.cel.expr.Value) resultKind_;
}
return dev.cel.expr.Value.getDefaultInstance();
}
/**
*
* 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 result_value = 8;
*/
@java.lang.Override
public dev.cel.expr.ValueOrBuilder getResultValueOrBuilder() {
if (resultKindCase_ == 8) {
return (dev.cel.expr.Value) resultKind_;
}
return dev.cel.expr.Value.getDefaultInstance();
}
public static final int RESULT_EXPR_FIELD_NUMBER = 9;
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return Whether the resultExpr field is set.
*/
public boolean hasResultExpr() {
return resultKindCase_ == 9;
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return The resultExpr.
*/
public java.lang.String getResultExpr() {
java.lang.Object ref = "";
if (resultKindCase_ == 9) {
ref = resultKind_;
}
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (resultKindCase_ == 9) {
resultKind_ = s;
}
return s;
}
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return The bytes for resultExpr.
*/
public com.google.protobuf.ByteString
getResultExprBytes() {
java.lang.Object ref = "";
if (resultKindCase_ == 9) {
ref = resultKind_;
}
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (resultKindCase_ == 9) {
resultKind_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int EVAL_ERROR_FIELD_NUMBER = 10;
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
* @return Whether the evalError field is set.
*/
@java.lang.Override
public boolean hasEvalError() {
return resultKindCase_ == 10;
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
* @return The evalError.
*/
@java.lang.Override
public dev.cel.expr.ErrorSet getEvalError() {
if (resultKindCase_ == 10) {
return (dev.cel.expr.ErrorSet) resultKind_;
}
return dev.cel.expr.ErrorSet.getDefaultInstance();
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
@java.lang.Override
public dev.cel.expr.ErrorSetOrBuilder getEvalErrorOrBuilder() {
if (resultKindCase_ == 10) {
return (dev.cel.expr.ErrorSet) resultKind_;
}
return dev.cel.expr.ErrorSet.getDefaultInstance();
}
public static final int UNKNOWN_FIELD_NUMBER = 11;
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
* @return Whether the unknown field is set.
*/
@java.lang.Override
public boolean hasUnknown() {
return resultKindCase_ == 11;
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
* @return The unknown.
*/
@java.lang.Override
public dev.cel.expr.UnknownSet getUnknown() {
if (resultKindCase_ == 11) {
return (dev.cel.expr.UnknownSet) resultKind_;
}
return dev.cel.expr.UnknownSet.getDefaultInstance();
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
@java.lang.Override
public dev.cel.expr.UnknownSetOrBuilder getUnknownOrBuilder() {
if (resultKindCase_ == 11) {
return (dev.cel.expr.UnknownSet) resultKind_;
}
return dev.cel.expr.UnknownSet.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (resultKindCase_ == 8) {
output.writeMessage(8, (dev.cel.expr.Value) resultKind_);
}
if (resultKindCase_ == 9) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 9, resultKind_);
}
if (resultKindCase_ == 10) {
output.writeMessage(10, (dev.cel.expr.ErrorSet) resultKind_);
}
if (resultKindCase_ == 11) {
output.writeMessage(11, (dev.cel.expr.UnknownSet) resultKind_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (resultKindCase_ == 8) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, (dev.cel.expr.Value) resultKind_);
}
if (resultKindCase_ == 9) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, resultKind_);
}
if (resultKindCase_ == 10) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(10, (dev.cel.expr.ErrorSet) resultKind_);
}
if (resultKindCase_ == 11) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(11, (dev.cel.expr.UnknownSet) resultKind_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof dev.cel.expr.conformance.test.TestOutput)) {
return super.equals(obj);
}
dev.cel.expr.conformance.test.TestOutput other = (dev.cel.expr.conformance.test.TestOutput) obj;
if (!getResultKindCase().equals(other.getResultKindCase())) return false;
switch (resultKindCase_) {
case 8:
if (!getResultValue()
.equals(other.getResultValue())) return false;
break;
case 9:
if (!getResultExpr()
.equals(other.getResultExpr())) return false;
break;
case 10:
if (!getEvalError()
.equals(other.getEvalError())) return false;
break;
case 11:
if (!getUnknown()
.equals(other.getUnknown())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
switch (resultKindCase_) {
case 8:
hash = (37 * hash) + RESULT_VALUE_FIELD_NUMBER;
hash = (53 * hash) + getResultValue().hashCode();
break;
case 9:
hash = (37 * hash) + RESULT_EXPR_FIELD_NUMBER;
hash = (53 * hash) + getResultExpr().hashCode();
break;
case 10:
hash = (37 * hash) + EVAL_ERROR_FIELD_NUMBER;
hash = (53 * hash) + getEvalError().hashCode();
break;
case 11:
hash = (37 * hash) + UNKNOWN_FIELD_NUMBER;
hash = (53 * hash) + getUnknown().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static dev.cel.expr.conformance.test.TestOutput parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static dev.cel.expr.conformance.test.TestOutput parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static dev.cel.expr.conformance.test.TestOutput parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(dev.cel.expr.conformance.test.TestOutput prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Expected result of the test case.
*
*
* Protobuf type {@code cel.expr.conformance.test.TestOutput}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:cel.expr.conformance.test.TestOutput)
dev.cel.expr.conformance.test.TestOutputOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return dev.cel.expr.conformance.test.SuiteProto.internal_static_cel_expr_conformance_test_TestOutput_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return dev.cel.expr.conformance.test.SuiteProto.internal_static_cel_expr_conformance_test_TestOutput_fieldAccessorTable
.ensureFieldAccessorsInitialized(
dev.cel.expr.conformance.test.TestOutput.class, dev.cel.expr.conformance.test.TestOutput.Builder.class);
}
// Construct using dev.cel.expr.conformance.test.TestOutput.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (resultValueBuilder_ != null) {
resultValueBuilder_.clear();
}
if (evalErrorBuilder_ != null) {
evalErrorBuilder_.clear();
}
if (unknownBuilder_ != null) {
unknownBuilder_.clear();
}
resultKindCase_ = 0;
resultKind_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return dev.cel.expr.conformance.test.SuiteProto.internal_static_cel_expr_conformance_test_TestOutput_descriptor;
}
@java.lang.Override
public dev.cel.expr.conformance.test.TestOutput getDefaultInstanceForType() {
return dev.cel.expr.conformance.test.TestOutput.getDefaultInstance();
}
@java.lang.Override
public dev.cel.expr.conformance.test.TestOutput build() {
dev.cel.expr.conformance.test.TestOutput result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public dev.cel.expr.conformance.test.TestOutput buildPartial() {
dev.cel.expr.conformance.test.TestOutput result = new dev.cel.expr.conformance.test.TestOutput(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(dev.cel.expr.conformance.test.TestOutput result) {
int from_bitField0_ = bitField0_;
}
private void buildPartialOneofs(dev.cel.expr.conformance.test.TestOutput result) {
result.resultKindCase_ = resultKindCase_;
result.resultKind_ = this.resultKind_;
if (resultKindCase_ == 8 &&
resultValueBuilder_ != null) {
result.resultKind_ = resultValueBuilder_.build();
}
if (resultKindCase_ == 10 &&
evalErrorBuilder_ != null) {
result.resultKind_ = evalErrorBuilder_.build();
}
if (resultKindCase_ == 11 &&
unknownBuilder_ != null) {
result.resultKind_ = unknownBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof dev.cel.expr.conformance.test.TestOutput) {
return mergeFrom((dev.cel.expr.conformance.test.TestOutput)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(dev.cel.expr.conformance.test.TestOutput other) {
if (other == dev.cel.expr.conformance.test.TestOutput.getDefaultInstance()) return this;
switch (other.getResultKindCase()) {
case RESULT_VALUE: {
mergeResultValue(other.getResultValue());
break;
}
case RESULT_EXPR: {
resultKindCase_ = 9;
resultKind_ = other.resultKind_;
onChanged();
break;
}
case EVAL_ERROR: {
mergeEvalError(other.getEvalError());
break;
}
case UNKNOWN: {
mergeUnknown(other.getUnknown());
break;
}
case RESULTKIND_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 66: {
input.readMessage(
getResultValueFieldBuilder().getBuilder(),
extensionRegistry);
resultKindCase_ = 8;
break;
} // case 66
case 74: {
java.lang.String s = input.readStringRequireUtf8();
resultKindCase_ = 9;
resultKind_ = s;
break;
} // case 74
case 82: {
input.readMessage(
getEvalErrorFieldBuilder().getBuilder(),
extensionRegistry);
resultKindCase_ = 10;
break;
} // case 82
case 90: {
input.readMessage(
getUnknownFieldBuilder().getBuilder(),
extensionRegistry);
resultKindCase_ = 11;
break;
} // case 90
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int resultKindCase_ = 0;
private java.lang.Object resultKind_;
public ResultKindCase
getResultKindCase() {
return ResultKindCase.forNumber(
resultKindCase_);
}
public Builder clearResultKind() {
resultKindCase_ = 0;
resultKind_ = null;
onChanged();
return this;
}
private int bitField0_;
private com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.Value, dev.cel.expr.Value.Builder, dev.cel.expr.ValueOrBuilder> resultValueBuilder_;
/**
*
* 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 result_value = 8;
* @return Whether the resultValue field is set.
*/
@java.lang.Override
public boolean hasResultValue() {
return resultKindCase_ == 8;
}
/**
*
* 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 result_value = 8;
* @return The resultValue.
*/
@java.lang.Override
public dev.cel.expr.Value getResultValue() {
if (resultValueBuilder_ == null) {
if (resultKindCase_ == 8) {
return (dev.cel.expr.Value) resultKind_;
}
return dev.cel.expr.Value.getDefaultInstance();
} else {
if (resultKindCase_ == 8) {
return resultValueBuilder_.getMessage();
}
return dev.cel.expr.Value.getDefaultInstance();
}
}
/**
*
* 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 result_value = 8;
*/
public Builder setResultValue(dev.cel.expr.Value value) {
if (resultValueBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
resultKind_ = value;
onChanged();
} else {
resultValueBuilder_.setMessage(value);
}
resultKindCase_ = 8;
return this;
}
/**
*
* 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 result_value = 8;
*/
public Builder setResultValue(
dev.cel.expr.Value.Builder builderForValue) {
if (resultValueBuilder_ == null) {
resultKind_ = builderForValue.build();
onChanged();
} else {
resultValueBuilder_.setMessage(builderForValue.build());
}
resultKindCase_ = 8;
return this;
}
/**
*
* 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 result_value = 8;
*/
public Builder mergeResultValue(dev.cel.expr.Value value) {
if (resultValueBuilder_ == null) {
if (resultKindCase_ == 8 &&
resultKind_ != dev.cel.expr.Value.getDefaultInstance()) {
resultKind_ = dev.cel.expr.Value.newBuilder((dev.cel.expr.Value) resultKind_)
.mergeFrom(value).buildPartial();
} else {
resultKind_ = value;
}
onChanged();
} else {
if (resultKindCase_ == 8) {
resultValueBuilder_.mergeFrom(value);
} else {
resultValueBuilder_.setMessage(value);
}
}
resultKindCase_ = 8;
return this;
}
/**
*
* 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 result_value = 8;
*/
public Builder clearResultValue() {
if (resultValueBuilder_ == null) {
if (resultKindCase_ == 8) {
resultKindCase_ = 0;
resultKind_ = null;
onChanged();
}
} else {
if (resultKindCase_ == 8) {
resultKindCase_ = 0;
resultKind_ = null;
}
resultValueBuilder_.clear();
}
return this;
}
/**
*
* 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 result_value = 8;
*/
public dev.cel.expr.Value.Builder getResultValueBuilder() {
return getResultValueFieldBuilder().getBuilder();
}
/**
*
* 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 result_value = 8;
*/
@java.lang.Override
public dev.cel.expr.ValueOrBuilder getResultValueOrBuilder() {
if ((resultKindCase_ == 8) && (resultValueBuilder_ != null)) {
return resultValueBuilder_.getMessageOrBuilder();
} else {
if (resultKindCase_ == 8) {
return (dev.cel.expr.Value) resultKind_;
}
return dev.cel.expr.Value.getDefaultInstance();
}
}
/**
*
* 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 result_value = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.Value, dev.cel.expr.Value.Builder, dev.cel.expr.ValueOrBuilder>
getResultValueFieldBuilder() {
if (resultValueBuilder_ == null) {
if (!(resultKindCase_ == 8)) {
resultKind_ = dev.cel.expr.Value.getDefaultInstance();
}
resultValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.Value, dev.cel.expr.Value.Builder, dev.cel.expr.ValueOrBuilder>(
(dev.cel.expr.Value) resultKind_,
getParentForChildren(),
isClean());
resultKind_ = null;
}
resultKindCase_ = 8;
onChanged();
return resultValueBuilder_;
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return Whether the resultExpr field is set.
*/
@java.lang.Override
public boolean hasResultExpr() {
return resultKindCase_ == 9;
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return The resultExpr.
*/
@java.lang.Override
public java.lang.String getResultExpr() {
java.lang.Object ref = "";
if (resultKindCase_ == 9) {
ref = resultKind_;
}
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (resultKindCase_ == 9) {
resultKind_ = s;
}
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return The bytes for resultExpr.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getResultExprBytes() {
java.lang.Object ref = "";
if (resultKindCase_ == 9) {
ref = resultKind_;
}
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (resultKindCase_ == 9) {
resultKind_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @param value The resultExpr to set.
* @return This builder for chaining.
*/
public Builder setResultExpr(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
resultKindCase_ = 9;
resultKind_ = value;
onChanged();
return this;
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @return This builder for chaining.
*/
public Builder clearResultExpr() {
if (resultKindCase_ == 9) {
resultKindCase_ = 0;
resultKind_ = null;
onChanged();
}
return this;
}
/**
*
* An expression to be evaluated using the cel environment configured for
* the test suite. The result of this expression must match the result of
* the test case.
*
*
* string result_expr = 9;
* @param value The bytes for resultExpr to set.
* @return This builder for chaining.
*/
public Builder setResultExprBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
resultKindCase_ = 9;
resultKind_ = value;
onChanged();
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.ErrorSet, dev.cel.expr.ErrorSet.Builder, dev.cel.expr.ErrorSetOrBuilder> evalErrorBuilder_;
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
* @return Whether the evalError field is set.
*/
@java.lang.Override
public boolean hasEvalError() {
return resultKindCase_ == 10;
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
* @return The evalError.
*/
@java.lang.Override
public dev.cel.expr.ErrorSet getEvalError() {
if (evalErrorBuilder_ == null) {
if (resultKindCase_ == 10) {
return (dev.cel.expr.ErrorSet) resultKind_;
}
return dev.cel.expr.ErrorSet.getDefaultInstance();
} else {
if (resultKindCase_ == 10) {
return evalErrorBuilder_.getMessage();
}
return dev.cel.expr.ErrorSet.getDefaultInstance();
}
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
public Builder setEvalError(dev.cel.expr.ErrorSet value) {
if (evalErrorBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
resultKind_ = value;
onChanged();
} else {
evalErrorBuilder_.setMessage(value);
}
resultKindCase_ = 10;
return this;
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
public Builder setEvalError(
dev.cel.expr.ErrorSet.Builder builderForValue) {
if (evalErrorBuilder_ == null) {
resultKind_ = builderForValue.build();
onChanged();
} else {
evalErrorBuilder_.setMessage(builderForValue.build());
}
resultKindCase_ = 10;
return this;
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
public Builder mergeEvalError(dev.cel.expr.ErrorSet value) {
if (evalErrorBuilder_ == null) {
if (resultKindCase_ == 10 &&
resultKind_ != dev.cel.expr.ErrorSet.getDefaultInstance()) {
resultKind_ = dev.cel.expr.ErrorSet.newBuilder((dev.cel.expr.ErrorSet) resultKind_)
.mergeFrom(value).buildPartial();
} else {
resultKind_ = value;
}
onChanged();
} else {
if (resultKindCase_ == 10) {
evalErrorBuilder_.mergeFrom(value);
} else {
evalErrorBuilder_.setMessage(value);
}
}
resultKindCase_ = 10;
return this;
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
public Builder clearEvalError() {
if (evalErrorBuilder_ == null) {
if (resultKindCase_ == 10) {
resultKindCase_ = 0;
resultKind_ = null;
onChanged();
}
} else {
if (resultKindCase_ == 10) {
resultKindCase_ = 0;
resultKind_ = null;
}
evalErrorBuilder_.clear();
}
return this;
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
public dev.cel.expr.ErrorSet.Builder getEvalErrorBuilder() {
return getEvalErrorFieldBuilder().getBuilder();
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
@java.lang.Override
public dev.cel.expr.ErrorSetOrBuilder getEvalErrorOrBuilder() {
if ((resultKindCase_ == 10) && (evalErrorBuilder_ != null)) {
return evalErrorBuilder_.getMessageOrBuilder();
} else {
if (resultKindCase_ == 10) {
return (dev.cel.expr.ErrorSet) resultKind_;
}
return dev.cel.expr.ErrorSet.getDefaultInstance();
}
}
/**
*
* An error evaluation result set. Success if we match all of the errors in
* the set.
*
*
* .cel.expr.ErrorSet eval_error = 10;
*/
private com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.ErrorSet, dev.cel.expr.ErrorSet.Builder, dev.cel.expr.ErrorSetOrBuilder>
getEvalErrorFieldBuilder() {
if (evalErrorBuilder_ == null) {
if (!(resultKindCase_ == 10)) {
resultKind_ = dev.cel.expr.ErrorSet.getDefaultInstance();
}
evalErrorBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.ErrorSet, dev.cel.expr.ErrorSet.Builder, dev.cel.expr.ErrorSetOrBuilder>(
(dev.cel.expr.ErrorSet) resultKind_,
getParentForChildren(),
isClean());
resultKind_ = null;
}
resultKindCase_ = 10;
onChanged();
return evalErrorBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.UnknownSet, dev.cel.expr.UnknownSet.Builder, dev.cel.expr.UnknownSetOrBuilder> unknownBuilder_;
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
* @return Whether the unknown field is set.
*/
@java.lang.Override
public boolean hasUnknown() {
return resultKindCase_ == 11;
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
* @return The unknown.
*/
@java.lang.Override
public dev.cel.expr.UnknownSet getUnknown() {
if (unknownBuilder_ == null) {
if (resultKindCase_ == 11) {
return (dev.cel.expr.UnknownSet) resultKind_;
}
return dev.cel.expr.UnknownSet.getDefaultInstance();
} else {
if (resultKindCase_ == 11) {
return unknownBuilder_.getMessage();
}
return dev.cel.expr.UnknownSet.getDefaultInstance();
}
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
public Builder setUnknown(dev.cel.expr.UnknownSet value) {
if (unknownBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
resultKind_ = value;
onChanged();
} else {
unknownBuilder_.setMessage(value);
}
resultKindCase_ = 11;
return this;
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
public Builder setUnknown(
dev.cel.expr.UnknownSet.Builder builderForValue) {
if (unknownBuilder_ == null) {
resultKind_ = builderForValue.build();
onChanged();
} else {
unknownBuilder_.setMessage(builderForValue.build());
}
resultKindCase_ = 11;
return this;
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
public Builder mergeUnknown(dev.cel.expr.UnknownSet value) {
if (unknownBuilder_ == null) {
if (resultKindCase_ == 11 &&
resultKind_ != dev.cel.expr.UnknownSet.getDefaultInstance()) {
resultKind_ = dev.cel.expr.UnknownSet.newBuilder((dev.cel.expr.UnknownSet) resultKind_)
.mergeFrom(value).buildPartial();
} else {
resultKind_ = value;
}
onChanged();
} else {
if (resultKindCase_ == 11) {
unknownBuilder_.mergeFrom(value);
} else {
unknownBuilder_.setMessage(value);
}
}
resultKindCase_ = 11;
return this;
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
public Builder clearUnknown() {
if (unknownBuilder_ == null) {
if (resultKindCase_ == 11) {
resultKindCase_ = 0;
resultKind_ = null;
onChanged();
}
} else {
if (resultKindCase_ == 11) {
resultKindCase_ = 0;
resultKind_ = null;
}
unknownBuilder_.clear();
}
return this;
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
public dev.cel.expr.UnknownSet.Builder getUnknownBuilder() {
return getUnknownFieldBuilder().getBuilder();
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
@java.lang.Override
public dev.cel.expr.UnknownSetOrBuilder getUnknownOrBuilder() {
if ((resultKindCase_ == 11) && (unknownBuilder_ != null)) {
return unknownBuilder_.getMessageOrBuilder();
} else {
if (resultKindCase_ == 11) {
return (dev.cel.expr.UnknownSet) resultKind_;
}
return dev.cel.expr.UnknownSet.getDefaultInstance();
}
}
/**
*
* An unknown evaluation result.
*
*
* .cel.expr.UnknownSet unknown = 11;
*/
private com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.UnknownSet, dev.cel.expr.UnknownSet.Builder, dev.cel.expr.UnknownSetOrBuilder>
getUnknownFieldBuilder() {
if (unknownBuilder_ == null) {
if (!(resultKindCase_ == 11)) {
resultKind_ = dev.cel.expr.UnknownSet.getDefaultInstance();
}
unknownBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
dev.cel.expr.UnknownSet, dev.cel.expr.UnknownSet.Builder, dev.cel.expr.UnknownSetOrBuilder>(
(dev.cel.expr.UnknownSet) resultKind_,
getParentForChildren(),
isClean());
resultKind_ = null;
}
resultKindCase_ = 11;
onChanged();
return unknownBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:cel.expr.conformance.test.TestOutput)
}
// @@protoc_insertion_point(class_scope:cel.expr.conformance.test.TestOutput)
private static final dev.cel.expr.conformance.test.TestOutput DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new dev.cel.expr.conformance.test.TestOutput();
}
public static dev.cel.expr.conformance.test.TestOutput getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public TestOutput parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public dev.cel.expr.conformance.test.TestOutput getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy