public static final class DescriptorProtos.DescriptorProto.Builder extends GeneratedMessageV3.Builder<DescriptorProtos.DescriptorProto.Builder> implements DescriptorProtos.DescriptorProtoOrBuilder
Describes a message type.
Protobuf type google.protobuf.DescriptorProto
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addAllEnumType(Iterable<? extends DescriptorProtos.EnumDescriptorProto> values)
public DescriptorProtos.DescriptorProto.Builder addAllEnumType(Iterable<? extends DescriptorProtos.EnumDescriptorProto> values)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.EnumDescriptorProto>
|
Returns
addAllExtension(Iterable<? extends DescriptorProtos.FieldDescriptorProto> values)
public DescriptorProtos.DescriptorProto.Builder addAllExtension(Iterable<? extends DescriptorProtos.FieldDescriptorProto> values)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.FieldDescriptorProto>
|
Returns
addAllExtensionRange(Iterable<? extends DescriptorProtos.DescriptorProto.ExtensionRange> values)
public DescriptorProtos.DescriptorProto.Builder addAllExtensionRange(Iterable<? extends DescriptorProtos.DescriptorProto.ExtensionRange> values)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.DescriptorProto.ExtensionRange>
|
Returns
addAllField(Iterable<? extends DescriptorProtos.FieldDescriptorProto> values)
public DescriptorProtos.DescriptorProto.Builder addAllField(Iterable<? extends DescriptorProtos.FieldDescriptorProto> values)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.FieldDescriptorProto>
|
Returns
addAllNestedType(Iterable<? extends DescriptorProtos.DescriptorProto> values)
public DescriptorProtos.DescriptorProto.Builder addAllNestedType(Iterable<? extends DescriptorProtos.DescriptorProto> values)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.DescriptorProto>
|
Returns
addAllOneofDecl(Iterable<? extends DescriptorProtos.OneofDescriptorProto> values)
public DescriptorProtos.DescriptorProto.Builder addAllOneofDecl(Iterable<? extends DescriptorProtos.OneofDescriptorProto> values)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.OneofDescriptorProto>
|
Returns
addAllReservedName(Iterable<String> values)
public DescriptorProtos.DescriptorProto.Builder addAllReservedName(Iterable<String> values)
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Parameter
Returns
addAllReservedRange(Iterable<? extends DescriptorProtos.DescriptorProto.ReservedRange> values)
public DescriptorProtos.DescriptorProto.Builder addAllReservedRange(Iterable<? extends DescriptorProtos.DescriptorProto.ReservedRange> values)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Name | Description |
values | Iterable<? extends com.google.protobuf.DescriptorProtos.DescriptorProto.ReservedRange>
|
Returns
addEnumType(DescriptorProtos.EnumDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addEnumType(DescriptorProtos.EnumDescriptorProto value)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
addEnumType(DescriptorProtos.EnumDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addEnumType(DescriptorProtos.EnumDescriptorProto.Builder builderForValue)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
addEnumType(int index, DescriptorProtos.EnumDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addEnumType(int index, DescriptorProtos.EnumDescriptorProto value)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameters
Returns
addEnumType(int index, DescriptorProtos.EnumDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addEnumType(int index, DescriptorProtos.EnumDescriptorProto.Builder builderForValue)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameters
Returns
addEnumTypeBuilder()
public DescriptorProtos.EnumDescriptorProto.Builder addEnumTypeBuilder()
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Returns
addEnumTypeBuilder(int index)
public DescriptorProtos.EnumDescriptorProto.Builder addEnumTypeBuilder(int index)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
addExtension(DescriptorProtos.FieldDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addExtension(DescriptorProtos.FieldDescriptorProto value)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
addExtension(DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addExtension(DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
addExtension(int index, DescriptorProtos.FieldDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addExtension(int index, DescriptorProtos.FieldDescriptorProto value)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameters
Returns
addExtension(int index, DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addExtension(int index, DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameters
Returns
addExtensionBuilder()
public DescriptorProtos.FieldDescriptorProto.Builder addExtensionBuilder()
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Returns
addExtensionBuilder(int index)
public DescriptorProtos.FieldDescriptorProto.Builder addExtensionBuilder(int index)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
addExtensionRange(DescriptorProtos.DescriptorProto.ExtensionRange value)
public DescriptorProtos.DescriptorProto.Builder addExtensionRange(DescriptorProtos.DescriptorProto.ExtensionRange value)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
addExtensionRange(DescriptorProtos.DescriptorProto.ExtensionRange.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addExtensionRange(DescriptorProtos.DescriptorProto.ExtensionRange.Builder builderForValue)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
addExtensionRange(int index, DescriptorProtos.DescriptorProto.ExtensionRange value)
public DescriptorProtos.DescriptorProto.Builder addExtensionRange(int index, DescriptorProtos.DescriptorProto.ExtensionRange value)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameters
Returns
addExtensionRange(int index, DescriptorProtos.DescriptorProto.ExtensionRange.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addExtensionRange(int index, DescriptorProtos.DescriptorProto.ExtensionRange.Builder builderForValue)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameters
Returns
addExtensionRangeBuilder()
public DescriptorProtos.DescriptorProto.ExtensionRange.Builder addExtensionRangeBuilder()
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Returns
addExtensionRangeBuilder(int index)
public DescriptorProtos.DescriptorProto.ExtensionRange.Builder addExtensionRangeBuilder(int index)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
addField(DescriptorProtos.FieldDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addField(DescriptorProtos.FieldDescriptorProto value)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
addField(DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addField(DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
addField(int index, DescriptorProtos.FieldDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addField(int index, DescriptorProtos.FieldDescriptorProto value)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameters
Returns
addField(int index, DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addField(int index, DescriptorProtos.FieldDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameters
Returns
addFieldBuilder()
public DescriptorProtos.FieldDescriptorProto.Builder addFieldBuilder()
repeated .google.protobuf.FieldDescriptorProto field = 2;
Returns
addFieldBuilder(int index)
public DescriptorProtos.FieldDescriptorProto.Builder addFieldBuilder(int index)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
addNestedType(DescriptorProtos.DescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addNestedType(DescriptorProtos.DescriptorProto value)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
addNestedType(DescriptorProtos.DescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addNestedType(DescriptorProtos.DescriptorProto.Builder builderForValue)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
addNestedType(int index, DescriptorProtos.DescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addNestedType(int index, DescriptorProtos.DescriptorProto value)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameters
Returns
addNestedType(int index, DescriptorProtos.DescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addNestedType(int index, DescriptorProtos.DescriptorProto.Builder builderForValue)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameters
Returns
addNestedTypeBuilder()
public DescriptorProtos.DescriptorProto.Builder addNestedTypeBuilder()
repeated .google.protobuf.DescriptorProto nested_type = 3;
Returns
addNestedTypeBuilder(int index)
public DescriptorProtos.DescriptorProto.Builder addNestedTypeBuilder(int index)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
addOneofDecl(DescriptorProtos.OneofDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addOneofDecl(DescriptorProtos.OneofDescriptorProto value)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
addOneofDecl(DescriptorProtos.OneofDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addOneofDecl(DescriptorProtos.OneofDescriptorProto.Builder builderForValue)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
addOneofDecl(int index, DescriptorProtos.OneofDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder addOneofDecl(int index, DescriptorProtos.OneofDescriptorProto value)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameters
Returns
addOneofDecl(int index, DescriptorProtos.OneofDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addOneofDecl(int index, DescriptorProtos.OneofDescriptorProto.Builder builderForValue)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameters
Returns
addOneofDeclBuilder()
public DescriptorProtos.OneofDescriptorProto.Builder addOneofDeclBuilder()
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Returns
addOneofDeclBuilder(int index)
public DescriptorProtos.OneofDescriptorProto.Builder addOneofDeclBuilder(int index)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public DescriptorProtos.DescriptorProto.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
addReservedName(String value)
public DescriptorProtos.DescriptorProto.Builder addReservedName(String value)
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Parameter
Name | Description |
value | String
The reservedName to add.
|
Returns
addReservedNameBytes(ByteString value)
public DescriptorProtos.DescriptorProto.Builder addReservedNameBytes(ByteString value)
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Parameter
Name | Description |
value | ByteString
The bytes of the reservedName to add.
|
Returns
addReservedRange(DescriptorProtos.DescriptorProto.ReservedRange value)
public DescriptorProtos.DescriptorProto.Builder addReservedRange(DescriptorProtos.DescriptorProto.ReservedRange value)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
addReservedRange(DescriptorProtos.DescriptorProto.ReservedRange.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addReservedRange(DescriptorProtos.DescriptorProto.ReservedRange.Builder builderForValue)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
addReservedRange(int index, DescriptorProtos.DescriptorProto.ReservedRange value)
public DescriptorProtos.DescriptorProto.Builder addReservedRange(int index, DescriptorProtos.DescriptorProto.ReservedRange value)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameters
Returns
addReservedRange(int index, DescriptorProtos.DescriptorProto.ReservedRange.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder addReservedRange(int index, DescriptorProtos.DescriptorProto.ReservedRange.Builder builderForValue)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameters
Returns
addReservedRangeBuilder()
public DescriptorProtos.DescriptorProto.ReservedRange.Builder addReservedRangeBuilder()
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Returns
addReservedRangeBuilder(int index)
public DescriptorProtos.DescriptorProto.ReservedRange.Builder addReservedRangeBuilder(int index)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
build()
public DescriptorProtos.DescriptorProto build()
Returns
buildPartial()
public DescriptorProtos.DescriptorProto buildPartial()
Returns
clear()
public DescriptorProtos.DescriptorProto.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
Overrides
clearEnumType()
public DescriptorProtos.DescriptorProto.Builder clearEnumType()
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Returns
clearExtension()
public DescriptorProtos.DescriptorProto.Builder clearExtension()
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Returns
clearExtensionRange()
public DescriptorProtos.DescriptorProto.Builder clearExtensionRange()
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Returns
clearField()
public DescriptorProtos.DescriptorProto.Builder clearField()
repeated .google.protobuf.FieldDescriptorProto field = 2;
Returns
clearField(Descriptors.FieldDescriptor field)
public DescriptorProtos.DescriptorProto.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearName()
public DescriptorProtos.DescriptorProto.Builder clearName()
optional string name = 1;
Returns
clearNestedType()
public DescriptorProtos.DescriptorProto.Builder clearNestedType()
repeated .google.protobuf.DescriptorProto nested_type = 3;
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public DescriptorProtos.DescriptorProto.Builder clearOneof(Descriptors.OneofDescriptor oneof)
TODO(jieluo): Clear it when all subclasses have implemented this method.
Parameter
Returns
Overrides
clearOneofDecl()
public DescriptorProtos.DescriptorProto.Builder clearOneofDecl()
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Returns
clearOptions()
public DescriptorProtos.DescriptorProto.Builder clearOptions()
optional .google.protobuf.MessageOptions options = 7;
Returns
clearReservedName()
public DescriptorProtos.DescriptorProto.Builder clearReservedName()
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Returns
clearReservedRange()
public DescriptorProtos.DescriptorProto.Builder clearReservedRange()
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Returns
clone()
public DescriptorProtos.DescriptorProto.Builder clone()
Returns
Overrides
getDefaultInstanceForType()
public DescriptorProtos.DescriptorProto 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
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
Overrides
getEnumType(int index)
public DescriptorProtos.EnumDescriptorProto getEnumType(int index)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
getEnumTypeBuilder(int index)
public DescriptorProtos.EnumDescriptorProto.Builder getEnumTypeBuilder(int index)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
getEnumTypeBuilderList()
public List<DescriptorProtos.EnumDescriptorProto.Builder> getEnumTypeBuilderList()
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Returns
getEnumTypeCount()
public int getEnumTypeCount()
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Returns
getEnumTypeList()
public List<DescriptorProtos.EnumDescriptorProto> getEnumTypeList()
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Returns
getEnumTypeOrBuilder(int index)
public DescriptorProtos.EnumDescriptorProtoOrBuilder getEnumTypeOrBuilder(int index)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
getEnumTypeOrBuilderList()
public List<? extends DescriptorProtos.EnumDescriptorProtoOrBuilder> getEnumTypeOrBuilderList()
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.EnumDescriptorProtoOrBuilder> | |
getExtension(int index)
public DescriptorProtos.FieldDescriptorProto getExtension(int index)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
getExtensionBuilder(int index)
public DescriptorProtos.FieldDescriptorProto.Builder getExtensionBuilder(int index)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
getExtensionBuilderList()
public List<DescriptorProtos.FieldDescriptorProto.Builder> getExtensionBuilderList()
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Returns
getExtensionCount()
public int getExtensionCount()
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Returns
getExtensionList()
public List<DescriptorProtos.FieldDescriptorProto> getExtensionList()
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Returns
getExtensionOrBuilder(int index)
public DescriptorProtos.FieldDescriptorProtoOrBuilder getExtensionOrBuilder(int index)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
getExtensionOrBuilderList()
public List<? extends DescriptorProtos.FieldDescriptorProtoOrBuilder> getExtensionOrBuilderList()
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.FieldDescriptorProtoOrBuilder> | |
getExtensionRange(int index)
public DescriptorProtos.DescriptorProto.ExtensionRange getExtensionRange(int index)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
getExtensionRangeBuilder(int index)
public DescriptorProtos.DescriptorProto.ExtensionRange.Builder getExtensionRangeBuilder(int index)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
getExtensionRangeBuilderList()
public List<DescriptorProtos.DescriptorProto.ExtensionRange.Builder> getExtensionRangeBuilderList()
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Returns
getExtensionRangeCount()
public int getExtensionRangeCount()
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Returns
getExtensionRangeList()
public List<DescriptorProtos.DescriptorProto.ExtensionRange> getExtensionRangeList()
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Returns
getExtensionRangeOrBuilder(int index)
public DescriptorProtos.DescriptorProto.ExtensionRangeOrBuilder getExtensionRangeOrBuilder(int index)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
getExtensionRangeOrBuilderList()
public List<? extends DescriptorProtos.DescriptorProto.ExtensionRangeOrBuilder> getExtensionRangeOrBuilderList()
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.DescriptorProto.ExtensionRangeOrBuilder> | |
getField(int index)
public DescriptorProtos.FieldDescriptorProto getField(int index)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
getFieldBuilder(int index)
public DescriptorProtos.FieldDescriptorProto.Builder getFieldBuilder(int index)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
getFieldBuilderList()
public List<DescriptorProtos.FieldDescriptorProto.Builder> getFieldBuilderList()
repeated .google.protobuf.FieldDescriptorProto field = 2;
Returns
getFieldCount()
public int getFieldCount()
repeated .google.protobuf.FieldDescriptorProto field = 2;
Returns
getFieldList()
public List<DescriptorProtos.FieldDescriptorProto> getFieldList()
repeated .google.protobuf.FieldDescriptorProto field = 2;
Returns
getFieldOrBuilder(int index)
public DescriptorProtos.FieldDescriptorProtoOrBuilder getFieldOrBuilder(int index)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
getFieldOrBuilderList()
public List<? extends DescriptorProtos.FieldDescriptorProtoOrBuilder> getFieldOrBuilderList()
repeated .google.protobuf.FieldDescriptorProto field = 2;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.FieldDescriptorProtoOrBuilder> | |
getName()
optional string name = 1;
Returns
Type | Description |
String | The name.
|
getNameBytes()
public ByteString getNameBytes()
optional string name = 1;
Returns
getNestedType(int index)
public DescriptorProtos.DescriptorProto getNestedType(int index)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
getNestedTypeBuilder(int index)
public DescriptorProtos.DescriptorProto.Builder getNestedTypeBuilder(int index)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
getNestedTypeBuilderList()
public List<DescriptorProtos.DescriptorProto.Builder> getNestedTypeBuilderList()
repeated .google.protobuf.DescriptorProto nested_type = 3;
Returns
getNestedTypeCount()
public int getNestedTypeCount()
repeated .google.protobuf.DescriptorProto nested_type = 3;
Returns
getNestedTypeList()
public List<DescriptorProtos.DescriptorProto> getNestedTypeList()
repeated .google.protobuf.DescriptorProto nested_type = 3;
Returns
getNestedTypeOrBuilder(int index)
public DescriptorProtos.DescriptorProtoOrBuilder getNestedTypeOrBuilder(int index)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
getNestedTypeOrBuilderList()
public List<? extends DescriptorProtos.DescriptorProtoOrBuilder> getNestedTypeOrBuilderList()
repeated .google.protobuf.DescriptorProto nested_type = 3;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.DescriptorProtoOrBuilder> | |
getOneofDecl(int index)
public DescriptorProtos.OneofDescriptorProto getOneofDecl(int index)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
getOneofDeclBuilder(int index)
public DescriptorProtos.OneofDescriptorProto.Builder getOneofDeclBuilder(int index)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
getOneofDeclBuilderList()
public List<DescriptorProtos.OneofDescriptorProto.Builder> getOneofDeclBuilderList()
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Returns
getOneofDeclCount()
public int getOneofDeclCount()
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Returns
getOneofDeclList()
public List<DescriptorProtos.OneofDescriptorProto> getOneofDeclList()
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Returns
getOneofDeclOrBuilder(int index)
public DescriptorProtos.OneofDescriptorProtoOrBuilder getOneofDeclOrBuilder(int index)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
getOneofDeclOrBuilderList()
public List<? extends DescriptorProtos.OneofDescriptorProtoOrBuilder> getOneofDeclOrBuilderList()
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.OneofDescriptorProtoOrBuilder> | |
getOptions()
public DescriptorProtos.MessageOptions getOptions()
optional .google.protobuf.MessageOptions options = 7;
Returns
getOptionsBuilder()
public DescriptorProtos.MessageOptions.Builder getOptionsBuilder()
optional .google.protobuf.MessageOptions options = 7;
Returns
getOptionsOrBuilder()
public DescriptorProtos.MessageOptionsOrBuilder getOptionsOrBuilder()
optional .google.protobuf.MessageOptions options = 7;
Returns
getReservedName(int index)
public String getReservedName(int index)
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Parameter
Name | Description |
index | int
The index of the element to return.
|
Returns
Type | Description |
String | The reservedName at the given index.
|
getReservedNameBytes(int index)
public ByteString getReservedNameBytes(int index)
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Parameter
Name | Description |
index | int
The index of the value to return.
|
Returns
Type | Description |
ByteString | The bytes of the reservedName at the given index.
|
getReservedNameCount()
public int getReservedNameCount()
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Returns
Type | Description |
int | The count of reservedName.
|
getReservedNameList()
public ProtocolStringList getReservedNameList()
Reserved field names, which may not be used by fields in the same message.
A given name may only be reserved once.
repeated string reserved_name = 10;
Returns
getReservedRange(int index)
public DescriptorProtos.DescriptorProto.ReservedRange getReservedRange(int index)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
getReservedRangeBuilder(int index)
public DescriptorProtos.DescriptorProto.ReservedRange.Builder getReservedRangeBuilder(int index)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
getReservedRangeBuilderList()
public List<DescriptorProtos.DescriptorProto.ReservedRange.Builder> getReservedRangeBuilderList()
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Returns
getReservedRangeCount()
public int getReservedRangeCount()
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Returns
getReservedRangeList()
public List<DescriptorProtos.DescriptorProto.ReservedRange> getReservedRangeList()
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Returns
getReservedRangeOrBuilder(int index)
public DescriptorProtos.DescriptorProto.ReservedRangeOrBuilder getReservedRangeOrBuilder(int index)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
getReservedRangeOrBuilderList()
public List<? extends DescriptorProtos.DescriptorProto.ReservedRangeOrBuilder> getReservedRangeOrBuilderList()
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Returns
Type | Description |
List<? extends com.google.protobuf.DescriptorProtos.DescriptorProto.ReservedRangeOrBuilder> | |
hasName()
optional string name = 1;
Returns
Type | Description |
boolean | Whether the name field is set.
|
hasOptions()
public boolean hasOptions()
optional .google.protobuf.MessageOptions options = 7;
Returns
Type | Description |
boolean | Whether the options 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
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
public DescriptorProtos.DescriptorProto.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
Returns
Overrides
Exceptions
mergeFrom(DescriptorProtos.DescriptorProto other)
public DescriptorProtos.DescriptorProto.Builder mergeFrom(DescriptorProtos.DescriptorProto other)
Parameter
Returns
mergeFrom(Message other)
public DescriptorProtos.DescriptorProto.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
, then other
'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
Returns
Overrides
mergeOptions(DescriptorProtos.MessageOptions value)
public DescriptorProtos.DescriptorProto.Builder mergeOptions(DescriptorProtos.MessageOptions value)
optional .google.protobuf.MessageOptions options = 7;
Parameter
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final DescriptorProtos.DescriptorProto.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
removeEnumType(int index)
public DescriptorProtos.DescriptorProto.Builder removeEnumType(int index)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameter
Returns
removeExtension(int index)
public DescriptorProtos.DescriptorProto.Builder removeExtension(int index)
repeated .google.protobuf.FieldDescriptorProto extension = 6;
Parameter
Returns
removeExtensionRange(int index)
public DescriptorProtos.DescriptorProto.Builder removeExtensionRange(int index)
repeated .google.protobuf.DescriptorProto.ExtensionRange extension_range = 5;
Parameter
Returns
removeField(int index)
public DescriptorProtos.DescriptorProto.Builder removeField(int index)
repeated .google.protobuf.FieldDescriptorProto field = 2;
Parameter
Returns
removeNestedType(int index)
public DescriptorProtos.DescriptorProto.Builder removeNestedType(int index)
repeated .google.protobuf.DescriptorProto nested_type = 3;
Parameter
Returns
removeOneofDecl(int index)
public DescriptorProtos.DescriptorProto.Builder removeOneofDecl(int index)
repeated .google.protobuf.OneofDescriptorProto oneof_decl = 8;
Parameter
Returns
removeReservedRange(int index)
public DescriptorProtos.DescriptorProto.Builder removeReservedRange(int index)
repeated .google.protobuf.DescriptorProto.ReservedRange reserved_range = 9;
Parameter
Returns
setEnumType(int index, DescriptorProtos.EnumDescriptorProto value)
public DescriptorProtos.DescriptorProto.Builder setEnumType(int index, DescriptorProtos.EnumDescriptorProto value)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameters
Returns
setEnumType(int index, DescriptorProtos.EnumDescriptorProto.Builder builderForValue)
public DescriptorProtos.DescriptorProto.Builder setEnumType(int index, DescriptorProtos.EnumDescriptorProto.Builder builderForValue)
repeated .google.protobuf.EnumDescriptorProto enum_type = 4;
Parameters
Returns