public static final class DescriptorProtos.UninterpretedOption.Builder extends GeneratedMessageV3.Builder<DescriptorProtos.UninterpretedOption.Builder> implements DescriptorProtos.UninterpretedOptionOrBuilder
A message representing a option the parser does not recognize. This only appears in options protos created by the compiler::Parser class. DescriptorPool resolves these when building Descriptor objects. Therefore, options protos in descriptor objects (e.g. returned by Descriptor::options(), or produced by Descriptor::CopyTo()) will never have UninterpretedOptions in them.
Protobuf type google.protobuf.UninterpretedOption
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > DescriptorProtos.UninterpretedOption.BuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns | |
---|---|
Type | Description |
Descriptors.Descriptor |
Methods
addAllName(Iterable<? extends DescriptorProtos.UninterpretedOption.NamePart> values)
public DescriptorProtos.UninterpretedOption.Builder addAllName(Iterable<? extends DescriptorProtos.UninterpretedOption.NamePart> values)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
values |
Iterable<? extends com.google.protobuf.DescriptorProtos.UninterpretedOption.NamePart> |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
addName(DescriptorProtos.UninterpretedOption.NamePart value)
public DescriptorProtos.UninterpretedOption.Builder addName(DescriptorProtos.UninterpretedOption.NamePart value)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
value |
DescriptorProtos.UninterpretedOption.NamePart |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
addName(DescriptorProtos.UninterpretedOption.NamePart.Builder builderForValue)
public DescriptorProtos.UninterpretedOption.Builder addName(DescriptorProtos.UninterpretedOption.NamePart.Builder builderForValue)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
builderForValue |
DescriptorProtos.UninterpretedOption.NamePart.Builder |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
addName(int index, DescriptorProtos.UninterpretedOption.NamePart value)
public DescriptorProtos.UninterpretedOption.Builder addName(int index, DescriptorProtos.UninterpretedOption.NamePart value)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameters | |
---|---|
Name | Description |
index |
int |
value |
DescriptorProtos.UninterpretedOption.NamePart |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
addName(int index, DescriptorProtos.UninterpretedOption.NamePart.Builder builderForValue)
public DescriptorProtos.UninterpretedOption.Builder addName(int index, DescriptorProtos.UninterpretedOption.NamePart.Builder builderForValue)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameters | |
---|---|
Name | Description |
index |
int |
builderForValue |
DescriptorProtos.UninterpretedOption.NamePart.Builder |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
addNameBuilder()
public DescriptorProtos.UninterpretedOption.NamePart.Builder addNameBuilder()
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.NamePart.Builder |
addNameBuilder(int index)
public DescriptorProtos.UninterpretedOption.NamePart.Builder addNameBuilder(int index)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.NamePart.Builder |
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public DescriptorProtos.UninterpretedOption.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters | |
---|---|
Name | Description |
field |
Descriptors.FieldDescriptor |
value |
Object |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
build()
public DescriptorProtos.UninterpretedOption build()
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption |
buildPartial()
public DescriptorProtos.UninterpretedOption buildPartial()
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption |
clear()
public DescriptorProtos.UninterpretedOption.Builder clear()
Called by the initialization and clear code paths to allow subclasses to reset any of their builtin fields back to the initial values.
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
clearAggregateValue()
public DescriptorProtos.UninterpretedOption.Builder clearAggregateValue()
optional string aggregate_value = 8;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
clearDoubleValue()
public DescriptorProtos.UninterpretedOption.Builder clearDoubleValue()
optional double double_value = 6;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
clearField(Descriptors.FieldDescriptor field)
public DescriptorProtos.UninterpretedOption.Builder clearField(Descriptors.FieldDescriptor field)
Parameter | |
---|---|
Name | Description |
field |
Descriptors.FieldDescriptor |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
clearIdentifierValue()
public DescriptorProtos.UninterpretedOption.Builder clearIdentifierValue()
The value of the uninterpreted option, in whatever type the tokenizer identified it as during parsing. Exactly one of these should be set.
optional string identifier_value = 3;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
clearName()
public DescriptorProtos.UninterpretedOption.Builder clearName()
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
clearNegativeIntValue()
public DescriptorProtos.UninterpretedOption.Builder clearNegativeIntValue()
optional int64 negative_int_value = 5;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public DescriptorProtos.UninterpretedOption.Builder clearOneof(Descriptors.OneofDescriptor oneof)
TODO(jieluo): Clear it when all subclasses have implemented this method.
Parameter | |
---|---|
Name | Description |
oneof |
Descriptors.OneofDescriptor |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
clearPositiveIntValue()
public DescriptorProtos.UninterpretedOption.Builder clearPositiveIntValue()
optional uint64 positive_int_value = 4;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
clearStringValue()
public DescriptorProtos.UninterpretedOption.Builder clearStringValue()
optional bytes string_value = 7;
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
clone()
public DescriptorProtos.UninterpretedOption.Builder clone()
Clones the Builder.
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
getAggregateValue()
public String getAggregateValue()
optional string aggregate_value = 8;
Returns | |
---|---|
Type | Description |
String |
The aggregateValue. |
getAggregateValueBytes()
public ByteString getAggregateValueBytes()
optional string aggregate_value = 8;
Returns | |
---|---|
Type | Description |
ByteString |
The bytes for aggregateValue. |
getDefaultInstanceForType()
public DescriptorProtos.UninterpretedOption getDefaultInstanceForType()
Get an instance of the type with no fields set. Because no fields are set, all getters for
singular fields will return default values and repeated fields will appear empty. This may or
may not be a singleton. This differs from the getDefaultInstance()
method of generated
message classes in that this method is an abstract method of the MessageLite
interface
whereas getDefaultInstance()
is a static method of a specific class. They return the
same thing.
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Get the message's type's descriptor. This differs from the getDescriptor()
method of
generated message classes in that this method is an abstract method of the Message
interface whereas getDescriptor()
is a static method of a specific class. They return
the same thing.
Returns | |
---|---|
Type | Description |
Descriptors.Descriptor |
getDoubleValue()
public double getDoubleValue()
optional double double_value = 6;
Returns | |
---|---|
Type | Description |
double |
The doubleValue. |
getIdentifierValue()
public String getIdentifierValue()
The value of the uninterpreted option, in whatever type the tokenizer identified it as during parsing. Exactly one of these should be set.
optional string identifier_value = 3;
Returns | |
---|---|
Type | Description |
String |
The identifierValue. |
getIdentifierValueBytes()
public ByteString getIdentifierValueBytes()
The value of the uninterpreted option, in whatever type the tokenizer identified it as during parsing. Exactly one of these should be set.
optional string identifier_value = 3;
Returns | |
---|---|
Type | Description |
ByteString |
The bytes for identifierValue. |
getName(int index)
public DescriptorProtos.UninterpretedOption.NamePart getName(int index)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.NamePart |
getNameBuilder(int index)
public DescriptorProtos.UninterpretedOption.NamePart.Builder getNameBuilder(int index)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.NamePart.Builder |
getNameBuilderList()
public List<DescriptorProtos.UninterpretedOption.NamePart.Builder> getNameBuilderList()
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Returns | |
---|---|
Type | Description |
List<Builder> |
getNameCount()
public int getNameCount()
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Returns | |
---|---|
Type | Description |
int |
getNameList()
public List<DescriptorProtos.UninterpretedOption.NamePart> getNameList()
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Returns | |
---|---|
Type | Description |
List<NamePart> |
getNameOrBuilder(int index)
public DescriptorProtos.UninterpretedOption.NamePartOrBuilder getNameOrBuilder(int index)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.NamePartOrBuilder |
getNameOrBuilderList()
public List<? extends DescriptorProtos.UninterpretedOption.NamePartOrBuilder> getNameOrBuilderList()
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Returns | |
---|---|
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.UninterpretedOption.NamePartOrBuilder> |
getNegativeIntValue()
public long getNegativeIntValue()
optional int64 negative_int_value = 5;
Returns | |
---|---|
Type | Description |
long |
The negativeIntValue. |
getPositiveIntValue()
public long getPositiveIntValue()
optional uint64 positive_int_value = 4;
Returns | |
---|---|
Type | Description |
long |
The positiveIntValue. |
getStringValue()
public ByteString getStringValue()
optional bytes string_value = 7;
Returns | |
---|---|
Type | Description |
ByteString |
The stringValue. |
hasAggregateValue()
public boolean hasAggregateValue()
optional string aggregate_value = 8;
Returns | |
---|---|
Type | Description |
boolean |
Whether the aggregateValue field is set. |
hasDoubleValue()
public boolean hasDoubleValue()
optional double double_value = 6;
Returns | |
---|---|
Type | Description |
boolean |
Whether the doubleValue field is set. |
hasIdentifierValue()
public boolean hasIdentifierValue()
The value of the uninterpreted option, in whatever type the tokenizer identified it as during parsing. Exactly one of these should be set.
optional string identifier_value = 3;
Returns | |
---|---|
Type | Description |
boolean |
Whether the identifierValue field is set. |
hasNegativeIntValue()
public boolean hasNegativeIntValue()
optional int64 negative_int_value = 5;
Returns | |
---|---|
Type | Description |
boolean |
Whether the negativeIntValue field is set. |
hasPositiveIntValue()
public boolean hasPositiveIntValue()
optional uint64 positive_int_value = 4;
Returns | |
---|---|
Type | Description |
boolean |
Whether the positiveIntValue field is set. |
hasStringValue()
public boolean hasStringValue()
optional bytes string_value = 7;
Returns | |
---|---|
Type | Description |
boolean |
Whether the stringValue field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Get the FieldAccessorTable for this type. We can't have the message class pass this in to the constructor because of bootstrapping trouble with DescriptorProtos.
Returns | |
---|---|
Type | Description |
GeneratedMessageV3.FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Returns true if all required fields in the message and all embedded messages are set, false otherwise.
Returns | |
---|---|
Type | Description |
boolean |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public DescriptorProtos.UninterpretedOption.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Like Builder#mergeFrom(CodedInputStream), but also parses extensions. The extensions
that you want to be able to parse must be registered in extensionRegistry
. Extensions
not in the registry will be treated as unknown fields.
Parameters | |
---|---|
Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
Exceptions | |
---|---|
Type | Description |
IOException |
mergeFrom(DescriptorProtos.UninterpretedOption other)
public DescriptorProtos.UninterpretedOption.Builder mergeFrom(DescriptorProtos.UninterpretedOption other)
Parameter | |
---|---|
Name | Description |
other |
DescriptorProtos.UninterpretedOption |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
mergeFrom(Message other)
public DescriptorProtos.UninterpretedOption.Builder mergeFrom(Message other)
Merge other
into the message being built. other
must have the exact same type
as this
(i.e. getDescriptorForType() == other.getDescriptorForType()
).
Merging occurs as follows. For each field:
- For singular primitive fields, if the field is set in
other
, thenother
's value overwrites the value in this message. - For singular message fields, if the field is set in
other
, it is merged into the corresponding sub-message of this message using the same merging rules. - For repeated fields, the elements in
other
are concatenated with the elements in this message. For oneof groups, if the other message has one of the fields set, the group of this message is cleared and replaced by the field of the other message, so that the oneof constraint is preserved.
This is equivalent to the
Message::MergeFrom
method in C++.
Parameter | |
---|---|
Name | Description |
other |
Message |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final DescriptorProtos.UninterpretedOption.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Merge some unknown fields into the UnknownFieldSet for this message.
Parameter | |
---|---|
Name | Description |
unknownFields |
UnknownFieldSet |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
removeName(int index)
public DescriptorProtos.UninterpretedOption.Builder removeName(int index)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
setAggregateValue(String value)
public DescriptorProtos.UninterpretedOption.Builder setAggregateValue(String value)
optional string aggregate_value = 8;
Parameter | |
---|---|
Name | Description |
value |
String The aggregateValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setAggregateValueBytes(ByteString value)
public DescriptorProtos.UninterpretedOption.Builder setAggregateValueBytes(ByteString value)
optional string aggregate_value = 8;
Parameter | |
---|---|
Name | Description |
value |
ByteString The bytes for aggregateValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setDoubleValue(double value)
public DescriptorProtos.UninterpretedOption.Builder setDoubleValue(double value)
optional double double_value = 6;
Parameter | |
---|---|
Name | Description |
value |
double The doubleValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setField(Descriptors.FieldDescriptor field, Object value)
public DescriptorProtos.UninterpretedOption.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters | |
---|---|
Name | Description |
field |
Descriptors.FieldDescriptor |
value |
Object |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
setIdentifierValue(String value)
public DescriptorProtos.UninterpretedOption.Builder setIdentifierValue(String value)
The value of the uninterpreted option, in whatever type the tokenizer identified it as during parsing. Exactly one of these should be set.
optional string identifier_value = 3;
Parameter | |
---|---|
Name | Description |
value |
String The identifierValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setIdentifierValueBytes(ByteString value)
public DescriptorProtos.UninterpretedOption.Builder setIdentifierValueBytes(ByteString value)
The value of the uninterpreted option, in whatever type the tokenizer identified it as during parsing. Exactly one of these should be set.
optional string identifier_value = 3;
Parameter | |
---|---|
Name | Description |
value |
ByteString The bytes for identifierValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setName(int index, DescriptorProtos.UninterpretedOption.NamePart value)
public DescriptorProtos.UninterpretedOption.Builder setName(int index, DescriptorProtos.UninterpretedOption.NamePart value)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameters | |
---|---|
Name | Description |
index |
int |
value |
DescriptorProtos.UninterpretedOption.NamePart |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
setName(int index, DescriptorProtos.UninterpretedOption.NamePart.Builder builderForValue)
public DescriptorProtos.UninterpretedOption.Builder setName(int index, DescriptorProtos.UninterpretedOption.NamePart.Builder builderForValue)
repeated .google.protobuf.UninterpretedOption.NamePart name = 2;
Parameters | |
---|---|
Name | Description |
index |
int |
builderForValue |
DescriptorProtos.UninterpretedOption.NamePart.Builder |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
setNegativeIntValue(long value)
public DescriptorProtos.UninterpretedOption.Builder setNegativeIntValue(long value)
optional int64 negative_int_value = 5;
Parameter | |
---|---|
Name | Description |
value |
long The negativeIntValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setPositiveIntValue(long value)
public DescriptorProtos.UninterpretedOption.Builder setPositiveIntValue(long value)
optional uint64 positive_int_value = 4;
Parameter | |
---|---|
Name | Description |
value |
long The positiveIntValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public DescriptorProtos.UninterpretedOption.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters | |
---|---|
Name | Description |
field |
Descriptors.FieldDescriptor |
index |
int |
value |
Object |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
setStringValue(ByteString value)
public DescriptorProtos.UninterpretedOption.Builder setStringValue(ByteString value)
optional bytes string_value = 7;
Parameter | |
---|---|
Name | Description |
value |
ByteString The stringValue to set. |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |
This builder for chaining. |
setUnknownFields(UnknownFieldSet unknownFields)
public final DescriptorProtos.UninterpretedOption.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields |
UnknownFieldSet |
Returns | |
---|---|
Type | Description |
DescriptorProtos.UninterpretedOption.Builder |