public static final class PluginProtos.CodeGeneratorRequest.Builder extends GeneratedMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder> implements PluginProtos.CodeGeneratorRequestOrBuilder
google.protobuf.compiler.CodeGeneratorRequest
An encoded CodeGeneratorRequest is written to the plugin's stdin.
Modifier and Type | Method and Description |
---|---|
PluginProtos.CodeGeneratorRequest.Builder |
addAllFileToGenerate(Iterable<String> values)
repeated string file_to_generate = 1; |
PluginProtos.CodeGeneratorRequest.Builder |
addAllProtoFile(Iterable<? extends DescriptorProtos.FileDescriptorProto> values)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest.Builder |
addFileToGenerate(String value)
repeated string file_to_generate = 1; |
PluginProtos.CodeGeneratorRequest.Builder |
addFileToGenerateBytes(ByteString value)
repeated string file_to_generate = 1; |
PluginProtos.CodeGeneratorRequest.Builder |
addProtoFile(DescriptorProtos.FileDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest.Builder |
addProtoFile(DescriptorProtos.FileDescriptorProto value)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest.Builder |
addProtoFile(int index,
DescriptorProtos.FileDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest.Builder |
addProtoFile(int index,
DescriptorProtos.FileDescriptorProto value)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
DescriptorProtos.FileDescriptorProto.Builder |
addProtoFileBuilder()
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
DescriptorProtos.FileDescriptorProto.Builder |
addProtoFileBuilder(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest |
build()
Constructs the message based on the state of the Builder.
|
PluginProtos.CodeGeneratorRequest |
buildPartial()
Like
MessageLite.Builder.build() , but does not throw an exception if the message
is missing required fields. |
PluginProtos.CodeGeneratorRequest.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.
|
PluginProtos.CodeGeneratorRequest.Builder |
clearFileToGenerate()
repeated string file_to_generate = 1; |
PluginProtos.CodeGeneratorRequest.Builder |
clearParameter()
optional string parameter = 2; |
PluginProtos.CodeGeneratorRequest.Builder |
clearProtoFile()
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest |
getDefaultInstanceForType()
Get an instance of the type with no fields set.
|
static Descriptors.Descriptor |
getDescriptor() |
Descriptors.Descriptor |
getDescriptorForType()
Get the message's type's descriptor.
|
String |
getFileToGenerate(int index)
repeated string file_to_generate = 1; |
ByteString |
getFileToGenerateBytes(int index)
repeated string file_to_generate = 1; |
int |
getFileToGenerateCount()
repeated string file_to_generate = 1; |
ProtocolStringList |
getFileToGenerateList()
repeated string file_to_generate = 1; |
String |
getParameter()
optional string parameter = 2; |
ByteString |
getParameterBytes()
optional string parameter = 2; |
DescriptorProtos.FileDescriptorProto |
getProtoFile(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
DescriptorProtos.FileDescriptorProto.Builder |
getProtoFileBuilder(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
List<DescriptorProtos.FileDescriptorProto.Builder> |
getProtoFileBuilderList()
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
int |
getProtoFileCount()
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
List<DescriptorProtos.FileDescriptorProto> |
getProtoFileList()
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
DescriptorProtos.FileDescriptorProtoOrBuilder |
getProtoFileOrBuilder(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
List<? extends DescriptorProtos.FileDescriptorProtoOrBuilder> |
getProtoFileOrBuilderList()
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
boolean |
hasParameter()
optional string parameter = 2; |
protected GeneratedMessage.FieldAccessorTable |
internalGetFieldAccessorTable()
Get the FieldAccessorTable for this type.
|
boolean |
isInitialized()
Returns true if all required fields in the message and all embedded
messages are set, false otherwise.
|
PluginProtos.CodeGeneratorRequest.Builder |
mergeFrom(CodedInputStream input,
ExtensionRegistryLite extensionRegistry)
Like
MessageLite.Builder.mergeFrom(CodedInputStream) , but also
parses extensions. |
PluginProtos.CodeGeneratorRequest.Builder |
mergeFrom(Message other)
Merge
other into the message being built. |
PluginProtos.CodeGeneratorRequest.Builder |
mergeFrom(PluginProtos.CodeGeneratorRequest other) |
PluginProtos.CodeGeneratorRequest.Builder |
removeProtoFile(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest.Builder |
setFileToGenerate(int index,
String value)
repeated string file_to_generate = 1; |
PluginProtos.CodeGeneratorRequest.Builder |
setParameter(String value)
optional string parameter = 2; |
PluginProtos.CodeGeneratorRequest.Builder |
setParameterBytes(ByteString value)
optional string parameter = 2; |
PluginProtos.CodeGeneratorRequest.Builder |
setProtoFile(int index,
DescriptorProtos.FileDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
PluginProtos.CodeGeneratorRequest.Builder |
setProtoFile(int index,
DescriptorProtos.FileDescriptorProto value)
repeated .google.protobuf.FileDescriptorProto proto_file = 15; |
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownFields, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields
findInitializationErrors, getInitializationErrorString, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
addAll, newUninitializedMessageException
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
public static final Descriptors.Descriptor getDescriptor()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
GeneratedMessage.Builder
internalGetFieldAccessorTable
in class GeneratedMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder>
public PluginProtos.CodeGeneratorRequest.Builder clear()
GeneratedMessage.Builder
clear
in interface Message.Builder
clear
in interface MessageLite.Builder
clear
in class GeneratedMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder>
public Descriptors.Descriptor getDescriptorForType()
Message.Builder
MessageOrBuilder.getDescriptorForType()
.getDescriptorForType
in interface Message.Builder
getDescriptorForType
in interface MessageOrBuilder
getDescriptorForType
in class GeneratedMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder>
public PluginProtos.CodeGeneratorRequest getDefaultInstanceForType()
MessageLiteOrBuilder
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.getDefaultInstanceForType
in interface MessageLiteOrBuilder
getDefaultInstanceForType
in interface MessageOrBuilder
public PluginProtos.CodeGeneratorRequest build()
MessageLite.Builder
build
in interface Message.Builder
build
in interface MessageLite.Builder
public PluginProtos.CodeGeneratorRequest buildPartial()
MessageLite.Builder
MessageLite.Builder.build()
, but does not throw an exception if the message
is missing required fields. Instead, a partial message is returned.
Subsequent changes to the Builder will not affect the returned message.buildPartial
in interface Message.Builder
buildPartial
in interface MessageLite.Builder
public PluginProtos.CodeGeneratorRequest.Builder mergeFrom(Message other)
Message.Builder
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:other
,
then other
's value overwrites the value in this message.other
,
it is merged into the corresponding sub-message of this message
using the same merging rules.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++.mergeFrom
in interface Message.Builder
mergeFrom
in class AbstractMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder>
public PluginProtos.CodeGeneratorRequest.Builder mergeFrom(PluginProtos.CodeGeneratorRequest other)
public final boolean isInitialized()
MessageLiteOrBuilder
isInitialized
in interface MessageLiteOrBuilder
isInitialized
in class GeneratedMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder>
public PluginProtos.CodeGeneratorRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) throws IOException
MessageLite.Builder
MessageLite.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.mergeFrom
in interface Message.Builder
mergeFrom
in interface MessageLite.Builder
mergeFrom
in class AbstractMessage.Builder<PluginProtos.CodeGeneratorRequest.Builder>
IOException
public ProtocolStringList getFileToGenerateList()
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
getFileToGenerateList
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public int getFileToGenerateCount()
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
getFileToGenerateCount
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public String getFileToGenerate(int index)
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
getFileToGenerate
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public ByteString getFileToGenerateBytes(int index)
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
getFileToGenerateBytes
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public PluginProtos.CodeGeneratorRequest.Builder setFileToGenerate(int index, String value)
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
public PluginProtos.CodeGeneratorRequest.Builder addFileToGenerate(String value)
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
public PluginProtos.CodeGeneratorRequest.Builder addAllFileToGenerate(Iterable<String> values)
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
public PluginProtos.CodeGeneratorRequest.Builder clearFileToGenerate()
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
public PluginProtos.CodeGeneratorRequest.Builder addFileToGenerateBytes(ByteString value)
repeated string file_to_generate = 1;
The .proto files that were explicitly listed on the command-line. The code generator should generate code only for these files. Each file's descriptor will be included in proto_file, below.
public boolean hasParameter()
optional string parameter = 2;
The generator parameter passed on the command-line.
hasParameter
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public String getParameter()
optional string parameter = 2;
The generator parameter passed on the command-line.
getParameter
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public ByteString getParameterBytes()
optional string parameter = 2;
The generator parameter passed on the command-line.
getParameterBytes
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public PluginProtos.CodeGeneratorRequest.Builder setParameter(String value)
optional string parameter = 2;
The generator parameter passed on the command-line.
public PluginProtos.CodeGeneratorRequest.Builder clearParameter()
optional string parameter = 2;
The generator parameter passed on the command-line.
public PluginProtos.CodeGeneratorRequest.Builder setParameterBytes(ByteString value)
optional string parameter = 2;
The generator parameter passed on the command-line.
public List<DescriptorProtos.FileDescriptorProto> getProtoFileList()
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
getProtoFileList
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public int getProtoFileCount()
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
getProtoFileCount
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public DescriptorProtos.FileDescriptorProto getProtoFile(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
getProtoFile
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public PluginProtos.CodeGeneratorRequest.Builder setProtoFile(int index, DescriptorProtos.FileDescriptorProto value)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder setProtoFile(int index, DescriptorProtos.FileDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder addProtoFile(DescriptorProtos.FileDescriptorProto value)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder addProtoFile(int index, DescriptorProtos.FileDescriptorProto value)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder addProtoFile(DescriptorProtos.FileDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder addProtoFile(int index, DescriptorProtos.FileDescriptorProto.Builder builderForValue)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder addAllProtoFile(Iterable<? extends DescriptorProtos.FileDescriptorProto> values)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder clearProtoFile()
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public PluginProtos.CodeGeneratorRequest.Builder removeProtoFile(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public DescriptorProtos.FileDescriptorProto.Builder getProtoFileBuilder(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public DescriptorProtos.FileDescriptorProtoOrBuilder getProtoFileOrBuilder(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
getProtoFileOrBuilder
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public List<? extends DescriptorProtos.FileDescriptorProtoOrBuilder> getProtoFileOrBuilderList()
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
getProtoFileOrBuilderList
in interface PluginProtos.CodeGeneratorRequestOrBuilder
public DescriptorProtos.FileDescriptorProto.Builder addProtoFileBuilder()
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public DescriptorProtos.FileDescriptorProto.Builder addProtoFileBuilder(int index)
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
public List<DescriptorProtos.FileDescriptorProto.Builder> getProtoFileBuilderList()
repeated .google.protobuf.FileDescriptorProto proto_file = 15;
FileDescriptorProtos for all files in files_to_generate and everything they import. The files will appear in topological order, so each file appears before any file that imports it. protoc guarantees that all proto_files will be written after the fields above, even though this is not technically guaranteed by the protobuf wire format. This theoretically could allow a plugin to stream in the FileDescriptorProtos and handle them one by one rather than read the entire set into memory at once. However, as of this writing, this is not similarly optimized on protoc's end -- it will store all fields in memory at once before sending them to the plugin.
Copyright © 2008–2016 Google. All rights reserved.