Package com.google.api.expr.v1beta1
Class Literal.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite.Builder<Literal,Literal.Builder>
com.google.api.expr.v1beta1.Literal.Builder
- All Implemented Interfaces:
LiteralOrBuilder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,Cloneable
- Enclosing class:
- Literal
public static final class Literal.Builder
extends com.google.protobuf.GeneratedMessageLite.Builder<Literal,Literal.Builder>
implements LiteralOrBuilder
Represents a primitive literal. This is similar to the primitives supported in the well-known type `google.protobuf.Value`, but richer so it can represent CEL's full range of primitives. Lists and structs are not included as constants as these aggregate types may contain [Expr][google.api.expr.v1beta1.Expr] elements which require evaluation and are thus not constant. Examples of literals include: `"hello"`, `b'bytes'`, `1u`, `4.2`, `-2`, `true`, `null`.Protobuf type
google.api.expr.v1beta1.Literal
-
Field Summary
Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder
instance
-
Method Summary
Modifier and TypeMethodDescriptionboolean value.bytes value.double value.int64 value.null value.string value.uint64 value.boolean
boolean value.com.google.protobuf.ByteString
bytes value.double
double value.long
int64 value.com.google.protobuf.NullValue
null value.int
null value.string value.com.google.protobuf.ByteString
string value.long
uint64 value.boolean
boolean value.boolean
bytes value.boolean
double value.boolean
int64 value.boolean
null value.boolean
string value.boolean
uint64 value.setBoolValue
(boolean value) boolean value.setBytesValue
(com.google.protobuf.ByteString value) bytes value.setDoubleValue
(double value) double value.setInt64Value
(long value) int64 value.setNullValue
(com.google.protobuf.NullValue value) null value.setNullValueValue
(int value) null value.setStringValue
(String value) string value.setStringValueBytes
(com.google.protobuf.ByteString value) string value.setUint64Value
(long value) uint64 value.Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder
build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFrom
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Method Details
-
getConstantKindCase
- Specified by:
getConstantKindCase
in interfaceLiteralOrBuilder
-
clearConstantKind
-
hasNullValue
public boolean hasNullValue()null value.
.google.protobuf.NullValue null_value = 1 [json_name = "nullValue"];
- Specified by:
hasNullValue
in interfaceLiteralOrBuilder
- Returns:
- Whether the nullValue field is set.
-
getNullValueValue
public int getNullValueValue()null value.
.google.protobuf.NullValue null_value = 1 [json_name = "nullValue"];
- Specified by:
getNullValueValue
in interfaceLiteralOrBuilder
- Returns:
- The enum numeric value on the wire for nullValue.
-
setNullValueValue
null value.
.google.protobuf.NullValue null_value = 1 [json_name = "nullValue"];
- Parameters:
value
- The enum numeric value on the wire for nullValue to set.- Returns:
- This builder for chaining.
-
getNullValue
public com.google.protobuf.NullValue getNullValue()null value.
.google.protobuf.NullValue null_value = 1 [json_name = "nullValue"];
- Specified by:
getNullValue
in interfaceLiteralOrBuilder
- Returns:
- The nullValue.
-
setNullValue
null value.
.google.protobuf.NullValue null_value = 1 [json_name = "nullValue"];
- Parameters:
value
- The nullValue to set.- Returns:
- This builder for chaining.
-
clearNullValue
null value.
.google.protobuf.NullValue null_value = 1 [json_name = "nullValue"];
- Returns:
- This builder for chaining.
-
hasBoolValue
public boolean hasBoolValue()boolean value.
bool bool_value = 2 [json_name = "boolValue"];
- Specified by:
hasBoolValue
in interfaceLiteralOrBuilder
- Returns:
- Whether the boolValue field is set.
-
getBoolValue
public boolean getBoolValue()boolean value.
bool bool_value = 2 [json_name = "boolValue"];
- Specified by:
getBoolValue
in interfaceLiteralOrBuilder
- Returns:
- The boolValue.
-
setBoolValue
boolean value.
bool bool_value = 2 [json_name = "boolValue"];
- Parameters:
value
- The boolValue to set.- Returns:
- This builder for chaining.
-
clearBoolValue
boolean value.
bool bool_value = 2 [json_name = "boolValue"];
- Returns:
- This builder for chaining.
-
hasInt64Value
public boolean hasInt64Value()int64 value.
int64 int64_value = 3 [json_name = "int64Value"];
- Specified by:
hasInt64Value
in interfaceLiteralOrBuilder
- Returns:
- Whether the int64Value field is set.
-
getInt64Value
public long getInt64Value()int64 value.
int64 int64_value = 3 [json_name = "int64Value"];
- Specified by:
getInt64Value
in interfaceLiteralOrBuilder
- Returns:
- The int64Value.
-
setInt64Value
int64 value.
int64 int64_value = 3 [json_name = "int64Value"];
- Parameters:
value
- The int64Value to set.- Returns:
- This builder for chaining.
-
clearInt64Value
int64 value.
int64 int64_value = 3 [json_name = "int64Value"];
- Returns:
- This builder for chaining.
-
hasUint64Value
public boolean hasUint64Value()uint64 value.
uint64 uint64_value = 4 [json_name = "uint64Value"];
- Specified by:
hasUint64Value
in interfaceLiteralOrBuilder
- Returns:
- Whether the uint64Value field is set.
-
getUint64Value
public long getUint64Value()uint64 value.
uint64 uint64_value = 4 [json_name = "uint64Value"];
- Specified by:
getUint64Value
in interfaceLiteralOrBuilder
- Returns:
- The uint64Value.
-
setUint64Value
uint64 value.
uint64 uint64_value = 4 [json_name = "uint64Value"];
- Parameters:
value
- The uint64Value to set.- Returns:
- This builder for chaining.
-
clearUint64Value
uint64 value.
uint64 uint64_value = 4 [json_name = "uint64Value"];
- Returns:
- This builder for chaining.
-
hasDoubleValue
public boolean hasDoubleValue()double value.
double double_value = 5 [json_name = "doubleValue"];
- Specified by:
hasDoubleValue
in interfaceLiteralOrBuilder
- Returns:
- Whether the doubleValue field is set.
-
getDoubleValue
public double getDoubleValue()double value.
double double_value = 5 [json_name = "doubleValue"];
- Specified by:
getDoubleValue
in interfaceLiteralOrBuilder
- Returns:
- The doubleValue.
-
setDoubleValue
double value.
double double_value = 5 [json_name = "doubleValue"];
- Parameters:
value
- The doubleValue to set.- Returns:
- This builder for chaining.
-
clearDoubleValue
double value.
double double_value = 5 [json_name = "doubleValue"];
- Returns:
- This builder for chaining.
-
hasStringValue
public boolean hasStringValue()string value.
string string_value = 6 [json_name = "stringValue"];
- Specified by:
hasStringValue
in interfaceLiteralOrBuilder
- Returns:
- Whether the stringValue field is set.
-
getStringValue
string value.
string string_value = 6 [json_name = "stringValue"];
- Specified by:
getStringValue
in interfaceLiteralOrBuilder
- Returns:
- The stringValue.
-
getStringValueBytes
public com.google.protobuf.ByteString getStringValueBytes()string value.
string string_value = 6 [json_name = "stringValue"];
- Specified by:
getStringValueBytes
in interfaceLiteralOrBuilder
- Returns:
- The bytes for stringValue.
-
setStringValue
string value.
string string_value = 6 [json_name = "stringValue"];
- Parameters:
value
- The stringValue to set.- Returns:
- This builder for chaining.
-
clearStringValue
string value.
string string_value = 6 [json_name = "stringValue"];
- Returns:
- This builder for chaining.
-
setStringValueBytes
string value.
string string_value = 6 [json_name = "stringValue"];
- Parameters:
value
- The bytes for stringValue to set.- Returns:
- This builder for chaining.
-
hasBytesValue
public boolean hasBytesValue()bytes value.
bytes bytes_value = 7 [json_name = "bytesValue"];
- Specified by:
hasBytesValue
in interfaceLiteralOrBuilder
- Returns:
- Whether the bytesValue field is set.
-
getBytesValue
public com.google.protobuf.ByteString getBytesValue()bytes value.
bytes bytes_value = 7 [json_name = "bytesValue"];
- Specified by:
getBytesValue
in interfaceLiteralOrBuilder
- Returns:
- The bytesValue.
-
setBytesValue
bytes value.
bytes bytes_value = 7 [json_name = "bytesValue"];
- Parameters:
value
- The bytesValue to set.- Returns:
- This builder for chaining.
-
clearBytesValue
bytes value.
bytes bytes_value = 7 [json_name = "bytesValue"];
- Returns:
- This builder for chaining.
-