|
|
|
@ -122,12 +122,12 @@ void MessageGenerator::GenerateStaticVariables(io::Printer* printer) { |
|
|
|
|
|
|
|
|
|
for (int i = 0; i < descriptor_->nested_type_count(); i++) { |
|
|
|
|
// Don't generate accessor table fields for maps...
|
|
|
|
|
if (IsMapEntryMessage(descriptor_->nested_type(i))) continue; |
|
|
|
|
|
|
|
|
|
if (!IsMapEntryMessage(descriptor_->nested_type(i))) { |
|
|
|
|
MessageGenerator messageGenerator(descriptor_->nested_type(i)); |
|
|
|
|
messageGenerator.GenerateStaticVariables(printer); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void MessageGenerator::GenerateStaticVariableInitializers(io::Printer* printer) { |
|
|
|
|
map<string, string> vars; |
|
|
|
@ -164,12 +164,12 @@ void MessageGenerator::GenerateStaticVariableInitializers(io::Printer* printer) |
|
|
|
|
|
|
|
|
|
// Generate static member initializers for all non-map-entry nested types.
|
|
|
|
|
for (int i = 0; i < descriptor_->nested_type_count(); i++) { |
|
|
|
|
if (IsMapEntryMessage(descriptor_->nested_type(i))) continue; |
|
|
|
|
|
|
|
|
|
if (!IsMapEntryMessage(descriptor_->nested_type(i))) { |
|
|
|
|
MessageGenerator messageGenerator(descriptor_->nested_type(i)); |
|
|
|
|
messageGenerator.GenerateStaticVariableInitializers(printer); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void MessageGenerator::Generate(io::Printer* printer) { |
|
|
|
|
map<string, string> vars; |
|
|
|
@ -302,11 +302,11 @@ void MessageGenerator::Generate(io::Printer* printer) { |
|
|
|
|
} |
|
|
|
|
for (int i = 0; i < descriptor_->nested_type_count(); i++) { |
|
|
|
|
// Don't generate nested types for maps...
|
|
|
|
|
if (IsMapEntryMessage(descriptor_->nested_type(i))) continue; |
|
|
|
|
|
|
|
|
|
if (!IsMapEntryMessage(descriptor_->nested_type(i))) { |
|
|
|
|
MessageGenerator messageGenerator(descriptor_->nested_type(i)); |
|
|
|
|
messageGenerator.Generate(printer); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
printer->Outdent(); |
|
|
|
|
printer->Print("}\n" |
|
|
|
|
"#endregion\n" |
|
|
|
|