blob: ef52def36ce180cfd08d4762126450d3875261ba [file] [log] [blame]
Brian Silverman9c614bc2016-02-15 20:20:02 -05001// Generated by the protocol buffer compiler. DO NOT EDIT!
2// source: google/protobuf/compiler/plugin.proto
3
Brian Silverman9c614bc2016-02-15 20:20:02 -05004#include <google/protobuf/compiler/plugin.pb.h>
5
6#include <algorithm>
7
8#include <google/protobuf/stubs/common.h>
9#include <google/protobuf/stubs/port.h>
Brian Silverman9c614bc2016-02-15 20:20:02 -050010#include <google/protobuf/io/coded_stream.h>
11#include <google/protobuf/wire_format_lite_inl.h>
12#include <google/protobuf/descriptor.h>
13#include <google/protobuf/generated_message_reflection.h>
14#include <google/protobuf/reflection_ops.h>
15#include <google/protobuf/wire_format.h>
Austin Schuh40c16522018-10-28 20:27:54 -070016// This is a temporary google only hack
17#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
18#include "third_party/protobuf/version.h"
19#endif
Brian Silverman9c614bc2016-02-15 20:20:02 -050020// @@protoc_insertion_point(includes)
21
Austin Schuh40c16522018-10-28 20:27:54 -070022namespace protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto {
23extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_CodeGeneratorResponse_File;
24extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Version;
25} // namespace protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto
26namespace protobuf_google_2fprotobuf_2fdescriptor_2eproto {
27extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fdescriptor_2eproto ::google::protobuf::internal::SCCInfo<6> scc_info_FileDescriptorProto;
28} // namespace protobuf_google_2fprotobuf_2fdescriptor_2eproto
29namespace google {
30namespace protobuf {
31namespace compiler {
32class VersionDefaultTypeInternal {
33 public:
34 ::google::protobuf::internal::ExplicitlyConstructed<Version>
35 _instance;
36} _Version_default_instance_;
37class CodeGeneratorRequestDefaultTypeInternal {
38 public:
39 ::google::protobuf::internal::ExplicitlyConstructed<CodeGeneratorRequest>
40 _instance;
41} _CodeGeneratorRequest_default_instance_;
42class CodeGeneratorResponse_FileDefaultTypeInternal {
43 public:
44 ::google::protobuf::internal::ExplicitlyConstructed<CodeGeneratorResponse_File>
45 _instance;
46} _CodeGeneratorResponse_File_default_instance_;
47class CodeGeneratorResponseDefaultTypeInternal {
48 public:
49 ::google::protobuf::internal::ExplicitlyConstructed<CodeGeneratorResponse>
50 _instance;
51} _CodeGeneratorResponse_default_instance_;
52} // namespace compiler
53} // namespace protobuf
54} // namespace google
55namespace protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto {
56static void InitDefaultsVersion() {
57 GOOGLE_PROTOBUF_VERIFY_VERSION;
58
59 {
60 void* ptr = &::google::protobuf::compiler::_Version_default_instance_;
61 new (ptr) ::google::protobuf::compiler::Version();
62 ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
63 }
64 ::google::protobuf::compiler::Version::InitAsDefaultInstance();
65}
66
67LIBPROTOC_EXPORT ::google::protobuf::internal::SCCInfo<0> scc_info_Version =
68 {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsVersion}, {}};
69
70static void InitDefaultsCodeGeneratorRequest() {
71 GOOGLE_PROTOBUF_VERIFY_VERSION;
72
73 {
74 void* ptr = &::google::protobuf::compiler::_CodeGeneratorRequest_default_instance_;
75 new (ptr) ::google::protobuf::compiler::CodeGeneratorRequest();
76 ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
77 }
78 ::google::protobuf::compiler::CodeGeneratorRequest::InitAsDefaultInstance();
79}
80
81LIBPROTOC_EXPORT ::google::protobuf::internal::SCCInfo<2> scc_info_CodeGeneratorRequest =
82 {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 2, InitDefaultsCodeGeneratorRequest}, {
83 &protobuf_google_2fprotobuf_2fdescriptor_2eproto::scc_info_FileDescriptorProto.base,
84 &protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_Version.base,}};
85
86static void InitDefaultsCodeGeneratorResponse_File() {
87 GOOGLE_PROTOBUF_VERIFY_VERSION;
88
89 {
90 void* ptr = &::google::protobuf::compiler::_CodeGeneratorResponse_File_default_instance_;
91 new (ptr) ::google::protobuf::compiler::CodeGeneratorResponse_File();
92 ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
93 }
94 ::google::protobuf::compiler::CodeGeneratorResponse_File::InitAsDefaultInstance();
95}
96
97LIBPROTOC_EXPORT ::google::protobuf::internal::SCCInfo<0> scc_info_CodeGeneratorResponse_File =
98 {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsCodeGeneratorResponse_File}, {}};
99
100static void InitDefaultsCodeGeneratorResponse() {
101 GOOGLE_PROTOBUF_VERIFY_VERSION;
102
103 {
104 void* ptr = &::google::protobuf::compiler::_CodeGeneratorResponse_default_instance_;
105 new (ptr) ::google::protobuf::compiler::CodeGeneratorResponse();
106 ::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
107 }
108 ::google::protobuf::compiler::CodeGeneratorResponse::InitAsDefaultInstance();
109}
110
111LIBPROTOC_EXPORT ::google::protobuf::internal::SCCInfo<1> scc_info_CodeGeneratorResponse =
112 {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsCodeGeneratorResponse}, {
113 &protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorResponse_File.base,}};
114
115void InitDefaults() {
116 ::google::protobuf::internal::InitSCC(&scc_info_Version.base);
117 ::google::protobuf::internal::InitSCC(&scc_info_CodeGeneratorRequest.base);
118 ::google::protobuf::internal::InitSCC(&scc_info_CodeGeneratorResponse_File.base);
119 ::google::protobuf::internal::InitSCC(&scc_info_CodeGeneratorResponse.base);
120}
121
122::google::protobuf::Metadata file_level_metadata[4];
123
124const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
125 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::Version, _has_bits_),
126 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::Version, _internal_metadata_),
127 ~0u, // no _extensions_
128 ~0u, // no _oneof_case_
129 ~0u, // no _weak_field_map_
130 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::Version, major_),
131 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::Version, minor_),
132 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::Version, patch_),
133 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::Version, suffix_),
134 1,
135 2,
136 3,
137 0,
138 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorRequest, _has_bits_),
139 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorRequest, _internal_metadata_),
140 ~0u, // no _extensions_
141 ~0u, // no _oneof_case_
142 ~0u, // no _weak_field_map_
143 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorRequest, file_to_generate_),
144 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorRequest, parameter_),
145 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorRequest, proto_file_),
146 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorRequest, compiler_version_),
147 ~0u,
148 0,
149 ~0u,
150 1,
151 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse_File, _has_bits_),
152 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse_File, _internal_metadata_),
153 ~0u, // no _extensions_
154 ~0u, // no _oneof_case_
155 ~0u, // no _weak_field_map_
156 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse_File, name_),
157 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse_File, insertion_point_),
158 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse_File, content_),
159 0,
160 1,
161 2,
162 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse, _has_bits_),
163 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse, _internal_metadata_),
164 ~0u, // no _extensions_
165 ~0u, // no _oneof_case_
166 ~0u, // no _weak_field_map_
167 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse, error_),
168 GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::compiler::CodeGeneratorResponse, file_),
169 0,
170 ~0u,
171};
172static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
173 { 0, 9, sizeof(::google::protobuf::compiler::Version)},
174 { 13, 22, sizeof(::google::protobuf::compiler::CodeGeneratorRequest)},
175 { 26, 34, sizeof(::google::protobuf::compiler::CodeGeneratorResponse_File)},
176 { 37, 44, sizeof(::google::protobuf::compiler::CodeGeneratorResponse)},
177};
178
179static ::google::protobuf::Message const * const file_default_instances[] = {
180 reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::compiler::_Version_default_instance_),
181 reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::compiler::_CodeGeneratorRequest_default_instance_),
182 reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::compiler::_CodeGeneratorResponse_File_default_instance_),
183 reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::compiler::_CodeGeneratorResponse_default_instance_),
184};
185
186void protobuf_AssignDescriptors() {
187 AddDescriptors();
188 AssignDescriptors(
189 "google/protobuf/compiler/plugin.proto", schemas, file_default_instances, TableStruct::offsets,
190 file_level_metadata, NULL, NULL);
191}
192
193void protobuf_AssignDescriptorsOnce() {
194 static ::google::protobuf::internal::once_flag once;
195 ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
196}
197
198void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
199void protobuf_RegisterTypes(const ::std::string&) {
200 protobuf_AssignDescriptorsOnce();
201 ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 4);
202}
203
204void AddDescriptorsImpl() {
205 InitDefaults();
206 static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
207 "\n%google/protobuf/compiler/plugin.proto\022"
208 "\030google.protobuf.compiler\032 google/protob"
209 "uf/descriptor.proto\"F\n\007Version\022\r\n\005major\030"
210 "\001 \001(\005\022\r\n\005minor\030\002 \001(\005\022\r\n\005patch\030\003 \001(\005\022\016\n\006s"
211 "uffix\030\004 \001(\t\"\272\001\n\024CodeGeneratorRequest\022\030\n\020"
212 "file_to_generate\030\001 \003(\t\022\021\n\tparameter\030\002 \001("
213 "\t\0228\n\nproto_file\030\017 \003(\0132$.google.protobuf."
214 "FileDescriptorProto\022;\n\020compiler_version\030"
215 "\003 \001(\0132!.google.protobuf.compiler.Version"
216 "\"\252\001\n\025CodeGeneratorResponse\022\r\n\005error\030\001 \001("
217 "\t\022B\n\004file\030\017 \003(\01324.google.protobuf.compil"
218 "er.CodeGeneratorResponse.File\032>\n\004File\022\014\n"
219 "\004name\030\001 \001(\t\022\027\n\017insertion_point\030\002 \001(\t\022\017\n\007"
220 "content\030\017 \001(\tBg\n\034com.google.protobuf.com"
221 "pilerB\014PluginProtosZ9github.com/golang/p"
222 "rotobuf/protoc-gen-go/plugin;plugin_go"
223 };
224 ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
225 descriptor, 638);
226 ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
227 "google/protobuf/compiler/plugin.proto", &protobuf_RegisterTypes);
228 ::protobuf_google_2fprotobuf_2fdescriptor_2eproto::AddDescriptors();
229}
230
231void AddDescriptors() {
232 static ::google::protobuf::internal::once_flag once;
233 ::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
234}
235// Force AddDescriptors() to be called at dynamic initialization time.
236struct StaticDescriptorInitializer {
237 StaticDescriptorInitializer() {
238 AddDescriptors();
239 }
240} static_descriptor_initializer;
241} // namespace protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto
Brian Silverman9c614bc2016-02-15 20:20:02 -0500242namespace google {
243namespace protobuf {
244namespace compiler {
245
Austin Schuh40c16522018-10-28 20:27:54 -0700246// ===================================================================
Brian Silverman9c614bc2016-02-15 20:20:02 -0500247
Austin Schuh40c16522018-10-28 20:27:54 -0700248void Version::InitAsDefaultInstance() {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500249}
Austin Schuh40c16522018-10-28 20:27:54 -0700250#if !defined(_MSC_VER) || _MSC_VER >= 1900
251const int Version::kMajorFieldNumber;
252const int Version::kMinorFieldNumber;
253const int Version::kPatchFieldNumber;
254const int Version::kSuffixFieldNumber;
255#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
Brian Silverman9c614bc2016-02-15 20:20:02 -0500256
Austin Schuh40c16522018-10-28 20:27:54 -0700257Version::Version()
258 : ::google::protobuf::Message(), _internal_metadata_(NULL) {
259 ::google::protobuf::internal::InitSCC(
260 &protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_Version.base);
261 SharedCtor();
262 // @@protoc_insertion_point(constructor:google.protobuf.compiler.Version)
Brian Silverman9c614bc2016-02-15 20:20:02 -0500263}
Austin Schuh40c16522018-10-28 20:27:54 -0700264Version::Version(const Version& from)
265 : ::google::protobuf::Message(),
266 _internal_metadata_(NULL),
267 _has_bits_(from._has_bits_) {
268 _internal_metadata_.MergeFrom(from._internal_metadata_);
269 suffix_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
270 if (from.has_suffix()) {
271 suffix_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.suffix_);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500272 }
Austin Schuh40c16522018-10-28 20:27:54 -0700273 ::memcpy(&major_, &from.major_,
274 static_cast<size_t>(reinterpret_cast<char*>(&patch_) -
275 reinterpret_cast<char*>(&major_)) + sizeof(patch_));
276 // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.Version)
Brian Silverman9c614bc2016-02-15 20:20:02 -0500277}
278
Austin Schuh40c16522018-10-28 20:27:54 -0700279void Version::SharedCtor() {
280 suffix_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
281 ::memset(&major_, 0, static_cast<size_t>(
282 reinterpret_cast<char*>(&patch_) -
283 reinterpret_cast<char*>(&major_)) + sizeof(patch_));
284}
285
286Version::~Version() {
287 // @@protoc_insertion_point(destructor:google.protobuf.compiler.Version)
288 SharedDtor();
289}
290
291void Version::SharedDtor() {
292 suffix_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
293}
294
295void Version::SetCachedSize(int size) const {
296 _cached_size_.Set(size);
297}
298const ::google::protobuf::Descriptor* Version::descriptor() {
299 ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
300 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
301}
302
303const Version& Version::default_instance() {
304 ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_Version.base);
305 return *internal_default_instance();
306}
307
308
309void Version::Clear() {
310// @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.Version)
311 ::google::protobuf::uint32 cached_has_bits = 0;
312 // Prevent compiler warnings about cached_has_bits being unused
313 (void) cached_has_bits;
314
315 cached_has_bits = _has_bits_[0];
316 if (cached_has_bits & 0x00000001u) {
317 suffix_.ClearNonDefaultToEmptyNoArena();
318 }
319 if (cached_has_bits & 14u) {
320 ::memset(&major_, 0, static_cast<size_t>(
321 reinterpret_cast<char*>(&patch_) -
322 reinterpret_cast<char*>(&major_)) + sizeof(patch_));
323 }
324 _has_bits_.Clear();
325 _internal_metadata_.Clear();
326}
327
328bool Version::MergePartialFromCodedStream(
329 ::google::protobuf::io::CodedInputStream* input) {
330#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
331 ::google::protobuf::uint32 tag;
332 // @@protoc_insertion_point(parse_start:google.protobuf.compiler.Version)
333 for (;;) {
334 ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
335 tag = p.first;
336 if (!p.second) goto handle_unusual;
337 switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
338 // optional int32 major = 1;
339 case 1: {
340 if (static_cast< ::google::protobuf::uint8>(tag) ==
341 static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
342 set_has_major();
343 DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
344 ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
345 input, &major_)));
346 } else {
347 goto handle_unusual;
348 }
349 break;
350 }
351
352 // optional int32 minor = 2;
353 case 2: {
354 if (static_cast< ::google::protobuf::uint8>(tag) ==
355 static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
356 set_has_minor();
357 DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
358 ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
359 input, &minor_)));
360 } else {
361 goto handle_unusual;
362 }
363 break;
364 }
365
366 // optional int32 patch = 3;
367 case 3: {
368 if (static_cast< ::google::protobuf::uint8>(tag) ==
369 static_cast< ::google::protobuf::uint8>(24u /* 24 & 0xFF */)) {
370 set_has_patch();
371 DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
372 ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
373 input, &patch_)));
374 } else {
375 goto handle_unusual;
376 }
377 break;
378 }
379
380 // optional string suffix = 4;
381 case 4: {
382 if (static_cast< ::google::protobuf::uint8>(tag) ==
383 static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
384 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
385 input, this->mutable_suffix()));
386 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
387 this->suffix().data(), static_cast<int>(this->suffix().length()),
388 ::google::protobuf::internal::WireFormat::PARSE,
389 "google.protobuf.compiler.Version.suffix");
390 } else {
391 goto handle_unusual;
392 }
393 break;
394 }
395
396 default: {
397 handle_unusual:
398 if (tag == 0) {
399 goto success;
400 }
401 DO_(::google::protobuf::internal::WireFormat::SkipField(
402 input, tag, _internal_metadata_.mutable_unknown_fields()));
403 break;
404 }
405 }
406 }
407success:
408 // @@protoc_insertion_point(parse_success:google.protobuf.compiler.Version)
409 return true;
410failure:
411 // @@protoc_insertion_point(parse_failure:google.protobuf.compiler.Version)
412 return false;
413#undef DO_
414}
415
416void Version::SerializeWithCachedSizes(
417 ::google::protobuf::io::CodedOutputStream* output) const {
418 // @@protoc_insertion_point(serialize_start:google.protobuf.compiler.Version)
419 ::google::protobuf::uint32 cached_has_bits = 0;
420 (void) cached_has_bits;
421
422 cached_has_bits = _has_bits_[0];
423 // optional int32 major = 1;
424 if (cached_has_bits & 0x00000002u) {
425 ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->major(), output);
426 }
427
428 // optional int32 minor = 2;
429 if (cached_has_bits & 0x00000004u) {
430 ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->minor(), output);
431 }
432
433 // optional int32 patch = 3;
434 if (cached_has_bits & 0x00000008u) {
435 ::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->patch(), output);
436 }
437
438 // optional string suffix = 4;
439 if (cached_has_bits & 0x00000001u) {
440 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
441 this->suffix().data(), static_cast<int>(this->suffix().length()),
442 ::google::protobuf::internal::WireFormat::SERIALIZE,
443 "google.protobuf.compiler.Version.suffix");
444 ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
445 4, this->suffix(), output);
446 }
447
448 if (_internal_metadata_.have_unknown_fields()) {
449 ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
450 _internal_metadata_.unknown_fields(), output);
451 }
452 // @@protoc_insertion_point(serialize_end:google.protobuf.compiler.Version)
453}
454
455::google::protobuf::uint8* Version::InternalSerializeWithCachedSizesToArray(
456 bool deterministic, ::google::protobuf::uint8* target) const {
457 (void)deterministic; // Unused
458 // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.Version)
459 ::google::protobuf::uint32 cached_has_bits = 0;
460 (void) cached_has_bits;
461
462 cached_has_bits = _has_bits_[0];
463 // optional int32 major = 1;
464 if (cached_has_bits & 0x00000002u) {
465 target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->major(), target);
466 }
467
468 // optional int32 minor = 2;
469 if (cached_has_bits & 0x00000004u) {
470 target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->minor(), target);
471 }
472
473 // optional int32 patch = 3;
474 if (cached_has_bits & 0x00000008u) {
475 target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->patch(), target);
476 }
477
478 // optional string suffix = 4;
479 if (cached_has_bits & 0x00000001u) {
480 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
481 this->suffix().data(), static_cast<int>(this->suffix().length()),
482 ::google::protobuf::internal::WireFormat::SERIALIZE,
483 "google.protobuf.compiler.Version.suffix");
484 target =
485 ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
486 4, this->suffix(), target);
487 }
488
489 if (_internal_metadata_.have_unknown_fields()) {
490 target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
491 _internal_metadata_.unknown_fields(), target);
492 }
493 // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.Version)
494 return target;
495}
496
497size_t Version::ByteSizeLong() const {
498// @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.Version)
499 size_t total_size = 0;
500
501 if (_internal_metadata_.have_unknown_fields()) {
502 total_size +=
503 ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
504 _internal_metadata_.unknown_fields());
505 }
506 if (_has_bits_[0 / 32] & 15u) {
507 // optional string suffix = 4;
508 if (has_suffix()) {
509 total_size += 1 +
510 ::google::protobuf::internal::WireFormatLite::StringSize(
511 this->suffix());
512 }
513
514 // optional int32 major = 1;
515 if (has_major()) {
516 total_size += 1 +
517 ::google::protobuf::internal::WireFormatLite::Int32Size(
518 this->major());
519 }
520
521 // optional int32 minor = 2;
522 if (has_minor()) {
523 total_size += 1 +
524 ::google::protobuf::internal::WireFormatLite::Int32Size(
525 this->minor());
526 }
527
528 // optional int32 patch = 3;
529 if (has_patch()) {
530 total_size += 1 +
531 ::google::protobuf::internal::WireFormatLite::Int32Size(
532 this->patch());
533 }
534
535 }
536 int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
537 SetCachedSize(cached_size);
538 return total_size;
539}
540
541void Version::MergeFrom(const ::google::protobuf::Message& from) {
542// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.compiler.Version)
543 GOOGLE_DCHECK_NE(&from, this);
544 const Version* source =
545 ::google::protobuf::internal::DynamicCastToGenerated<const Version>(
546 &from);
547 if (source == NULL) {
548 // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.compiler.Version)
549 ::google::protobuf::internal::ReflectionOps::Merge(from, this);
550 } else {
551 // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.compiler.Version)
552 MergeFrom(*source);
553 }
554}
555
556void Version::MergeFrom(const Version& from) {
557// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.Version)
558 GOOGLE_DCHECK_NE(&from, this);
559 _internal_metadata_.MergeFrom(from._internal_metadata_);
560 ::google::protobuf::uint32 cached_has_bits = 0;
561 (void) cached_has_bits;
562
563 cached_has_bits = from._has_bits_[0];
564 if (cached_has_bits & 15u) {
565 if (cached_has_bits & 0x00000001u) {
566 set_has_suffix();
567 suffix_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.suffix_);
568 }
569 if (cached_has_bits & 0x00000002u) {
570 major_ = from.major_;
571 }
572 if (cached_has_bits & 0x00000004u) {
573 minor_ = from.minor_;
574 }
575 if (cached_has_bits & 0x00000008u) {
576 patch_ = from.patch_;
577 }
578 _has_bits_[0] |= cached_has_bits;
579 }
580}
581
582void Version::CopyFrom(const ::google::protobuf::Message& from) {
583// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.compiler.Version)
584 if (&from == this) return;
585 Clear();
586 MergeFrom(from);
587}
588
589void Version::CopyFrom(const Version& from) {
590// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.Version)
591 if (&from == this) return;
592 Clear();
593 MergeFrom(from);
594}
595
596bool Version::IsInitialized() const {
597 return true;
598}
599
600void Version::Swap(Version* other) {
601 if (other == this) return;
602 InternalSwap(other);
603}
604void Version::InternalSwap(Version* other) {
605 using std::swap;
606 suffix_.Swap(&other->suffix_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
607 GetArenaNoVirtual());
608 swap(major_, other->major_);
609 swap(minor_, other->minor_);
610 swap(patch_, other->patch_);
611 swap(_has_bits_[0], other->_has_bits_[0]);
612 _internal_metadata_.Swap(&other->_internal_metadata_);
613}
614
615::google::protobuf::Metadata Version::GetMetadata() const {
616 protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
617 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages];
618}
Brian Silverman9c614bc2016-02-15 20:20:02 -0500619
620
621// ===================================================================
622
Austin Schuh40c16522018-10-28 20:27:54 -0700623void CodeGeneratorRequest::InitAsDefaultInstance() {
624 ::google::protobuf::compiler::_CodeGeneratorRequest_default_instance_._instance.get_mutable()->compiler_version_ = const_cast< ::google::protobuf::compiler::Version*>(
625 ::google::protobuf::compiler::Version::internal_default_instance());
626}
627void CodeGeneratorRequest::clear_proto_file() {
628 proto_file_.Clear();
629}
Brian Silverman9c614bc2016-02-15 20:20:02 -0500630#if !defined(_MSC_VER) || _MSC_VER >= 1900
631const int CodeGeneratorRequest::kFileToGenerateFieldNumber;
632const int CodeGeneratorRequest::kParameterFieldNumber;
633const int CodeGeneratorRequest::kProtoFileFieldNumber;
Austin Schuh40c16522018-10-28 20:27:54 -0700634const int CodeGeneratorRequest::kCompilerVersionFieldNumber;
Brian Silverman9c614bc2016-02-15 20:20:02 -0500635#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
636
637CodeGeneratorRequest::CodeGeneratorRequest()
638 : ::google::protobuf::Message(), _internal_metadata_(NULL) {
Austin Schuh40c16522018-10-28 20:27:54 -0700639 ::google::protobuf::internal::InitSCC(
640 &protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorRequest.base);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500641 SharedCtor();
642 // @@protoc_insertion_point(constructor:google.protobuf.compiler.CodeGeneratorRequest)
643}
Brian Silverman9c614bc2016-02-15 20:20:02 -0500644CodeGeneratorRequest::CodeGeneratorRequest(const CodeGeneratorRequest& from)
645 : ::google::protobuf::Message(),
Austin Schuh40c16522018-10-28 20:27:54 -0700646 _internal_metadata_(NULL),
647 _has_bits_(from._has_bits_),
648 file_to_generate_(from.file_to_generate_),
649 proto_file_(from.proto_file_) {
650 _internal_metadata_.MergeFrom(from._internal_metadata_);
651 parameter_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
652 if (from.has_parameter()) {
653 parameter_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.parameter_);
654 }
655 if (from.has_compiler_version()) {
656 compiler_version_ = new ::google::protobuf::compiler::Version(*from.compiler_version_);
657 } else {
658 compiler_version_ = NULL;
659 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500660 // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.CodeGeneratorRequest)
661}
662
663void CodeGeneratorRequest::SharedCtor() {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500664 parameter_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
Austin Schuh40c16522018-10-28 20:27:54 -0700665 compiler_version_ = NULL;
Brian Silverman9c614bc2016-02-15 20:20:02 -0500666}
667
668CodeGeneratorRequest::~CodeGeneratorRequest() {
669 // @@protoc_insertion_point(destructor:google.protobuf.compiler.CodeGeneratorRequest)
670 SharedDtor();
671}
672
673void CodeGeneratorRequest::SharedDtor() {
674 parameter_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
Austin Schuh40c16522018-10-28 20:27:54 -0700675 if (this != internal_default_instance()) delete compiler_version_;
Brian Silverman9c614bc2016-02-15 20:20:02 -0500676}
677
678void CodeGeneratorRequest::SetCachedSize(int size) const {
Austin Schuh40c16522018-10-28 20:27:54 -0700679 _cached_size_.Set(size);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500680}
681const ::google::protobuf::Descriptor* CodeGeneratorRequest::descriptor() {
Austin Schuh40c16522018-10-28 20:27:54 -0700682 ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
683 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
Brian Silverman9c614bc2016-02-15 20:20:02 -0500684}
685
686const CodeGeneratorRequest& CodeGeneratorRequest::default_instance() {
Austin Schuh40c16522018-10-28 20:27:54 -0700687 ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorRequest.base);
688 return *internal_default_instance();
Brian Silverman9c614bc2016-02-15 20:20:02 -0500689}
690
Brian Silverman9c614bc2016-02-15 20:20:02 -0500691
692void CodeGeneratorRequest::Clear() {
Austin Schuh40c16522018-10-28 20:27:54 -0700693// @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorRequest)
694 ::google::protobuf::uint32 cached_has_bits = 0;
695 // Prevent compiler warnings about cached_has_bits being unused
696 (void) cached_has_bits;
697
Brian Silverman9c614bc2016-02-15 20:20:02 -0500698 file_to_generate_.Clear();
699 proto_file_.Clear();
Austin Schuh40c16522018-10-28 20:27:54 -0700700 cached_has_bits = _has_bits_[0];
701 if (cached_has_bits & 3u) {
702 if (cached_has_bits & 0x00000001u) {
703 parameter_.ClearNonDefaultToEmptyNoArena();
704 }
705 if (cached_has_bits & 0x00000002u) {
706 GOOGLE_DCHECK(compiler_version_ != NULL);
707 compiler_version_->Clear();
708 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500709 }
Austin Schuh40c16522018-10-28 20:27:54 -0700710 _has_bits_.Clear();
711 _internal_metadata_.Clear();
Brian Silverman9c614bc2016-02-15 20:20:02 -0500712}
713
714bool CodeGeneratorRequest::MergePartialFromCodedStream(
715 ::google::protobuf::io::CodedInputStream* input) {
Austin Schuh40c16522018-10-28 20:27:54 -0700716#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
Brian Silverman9c614bc2016-02-15 20:20:02 -0500717 ::google::protobuf::uint32 tag;
718 // @@protoc_insertion_point(parse_start:google.protobuf.compiler.CodeGeneratorRequest)
719 for (;;) {
Austin Schuh40c16522018-10-28 20:27:54 -0700720 ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500721 tag = p.first;
722 if (!p.second) goto handle_unusual;
723 switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
724 // repeated string file_to_generate = 1;
725 case 1: {
Austin Schuh40c16522018-10-28 20:27:54 -0700726 if (static_cast< ::google::protobuf::uint8>(tag) ==
727 static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500728 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
729 input, this->add_file_to_generate()));
730 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
731 this->file_to_generate(this->file_to_generate_size() - 1).data(),
Austin Schuh40c16522018-10-28 20:27:54 -0700732 static_cast<int>(this->file_to_generate(this->file_to_generate_size() - 1).length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -0500733 ::google::protobuf::internal::WireFormat::PARSE,
734 "google.protobuf.compiler.CodeGeneratorRequest.file_to_generate");
735 } else {
736 goto handle_unusual;
737 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500738 break;
739 }
740
741 // optional string parameter = 2;
742 case 2: {
Austin Schuh40c16522018-10-28 20:27:54 -0700743 if (static_cast< ::google::protobuf::uint8>(tag) ==
744 static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500745 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
746 input, this->mutable_parameter()));
747 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -0700748 this->parameter().data(), static_cast<int>(this->parameter().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -0500749 ::google::protobuf::internal::WireFormat::PARSE,
750 "google.protobuf.compiler.CodeGeneratorRequest.parameter");
751 } else {
752 goto handle_unusual;
753 }
Austin Schuh40c16522018-10-28 20:27:54 -0700754 break;
755 }
756
757 // optional .google.protobuf.compiler.Version compiler_version = 3;
758 case 3: {
759 if (static_cast< ::google::protobuf::uint8>(tag) ==
760 static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
761 DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
762 input, mutable_compiler_version()));
763 } else {
764 goto handle_unusual;
765 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500766 break;
767 }
768
769 // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
770 case 15: {
Austin Schuh40c16522018-10-28 20:27:54 -0700771 if (static_cast< ::google::protobuf::uint8>(tag) ==
772 static_cast< ::google::protobuf::uint8>(122u /* 122 & 0xFF */)) {
773 DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
Brian Silverman9c614bc2016-02-15 20:20:02 -0500774 input, add_proto_file()));
775 } else {
776 goto handle_unusual;
777 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500778 break;
779 }
780
781 default: {
782 handle_unusual:
Austin Schuh40c16522018-10-28 20:27:54 -0700783 if (tag == 0) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500784 goto success;
785 }
786 DO_(::google::protobuf::internal::WireFormat::SkipField(
Austin Schuh40c16522018-10-28 20:27:54 -0700787 input, tag, _internal_metadata_.mutable_unknown_fields()));
Brian Silverman9c614bc2016-02-15 20:20:02 -0500788 break;
789 }
790 }
791 }
792success:
793 // @@protoc_insertion_point(parse_success:google.protobuf.compiler.CodeGeneratorRequest)
794 return true;
795failure:
796 // @@protoc_insertion_point(parse_failure:google.protobuf.compiler.CodeGeneratorRequest)
797 return false;
798#undef DO_
799}
800
801void CodeGeneratorRequest::SerializeWithCachedSizes(
802 ::google::protobuf::io::CodedOutputStream* output) const {
803 // @@protoc_insertion_point(serialize_start:google.protobuf.compiler.CodeGeneratorRequest)
Austin Schuh40c16522018-10-28 20:27:54 -0700804 ::google::protobuf::uint32 cached_has_bits = 0;
805 (void) cached_has_bits;
806
Brian Silverman9c614bc2016-02-15 20:20:02 -0500807 // repeated string file_to_generate = 1;
Austin Schuh40c16522018-10-28 20:27:54 -0700808 for (int i = 0, n = this->file_to_generate_size(); i < n; i++) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500809 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -0700810 this->file_to_generate(i).data(), static_cast<int>(this->file_to_generate(i).length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -0500811 ::google::protobuf::internal::WireFormat::SERIALIZE,
812 "google.protobuf.compiler.CodeGeneratorRequest.file_to_generate");
813 ::google::protobuf::internal::WireFormatLite::WriteString(
814 1, this->file_to_generate(i), output);
815 }
816
Austin Schuh40c16522018-10-28 20:27:54 -0700817 cached_has_bits = _has_bits_[0];
Brian Silverman9c614bc2016-02-15 20:20:02 -0500818 // optional string parameter = 2;
Austin Schuh40c16522018-10-28 20:27:54 -0700819 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500820 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -0700821 this->parameter().data(), static_cast<int>(this->parameter().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -0500822 ::google::protobuf::internal::WireFormat::SERIALIZE,
823 "google.protobuf.compiler.CodeGeneratorRequest.parameter");
824 ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
825 2, this->parameter(), output);
826 }
827
Austin Schuh40c16522018-10-28 20:27:54 -0700828 // optional .google.protobuf.compiler.Version compiler_version = 3;
829 if (cached_has_bits & 0x00000002u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500830 ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
Austin Schuh40c16522018-10-28 20:27:54 -0700831 3, this->_internal_compiler_version(), output);
832 }
833
834 // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
835 for (unsigned int i = 0,
836 n = static_cast<unsigned int>(this->proto_file_size()); i < n; i++) {
837 ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
838 15,
839 this->proto_file(static_cast<int>(i)),
840 output);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500841 }
842
843 if (_internal_metadata_.have_unknown_fields()) {
844 ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
Austin Schuh40c16522018-10-28 20:27:54 -0700845 _internal_metadata_.unknown_fields(), output);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500846 }
847 // @@protoc_insertion_point(serialize_end:google.protobuf.compiler.CodeGeneratorRequest)
848}
849
Austin Schuh40c16522018-10-28 20:27:54 -0700850::google::protobuf::uint8* CodeGeneratorRequest::InternalSerializeWithCachedSizesToArray(
851 bool deterministic, ::google::protobuf::uint8* target) const {
852 (void)deterministic; // Unused
Brian Silverman9c614bc2016-02-15 20:20:02 -0500853 // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.CodeGeneratorRequest)
Austin Schuh40c16522018-10-28 20:27:54 -0700854 ::google::protobuf::uint32 cached_has_bits = 0;
855 (void) cached_has_bits;
856
Brian Silverman9c614bc2016-02-15 20:20:02 -0500857 // repeated string file_to_generate = 1;
Austin Schuh40c16522018-10-28 20:27:54 -0700858 for (int i = 0, n = this->file_to_generate_size(); i < n; i++) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500859 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -0700860 this->file_to_generate(i).data(), static_cast<int>(this->file_to_generate(i).length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -0500861 ::google::protobuf::internal::WireFormat::SERIALIZE,
862 "google.protobuf.compiler.CodeGeneratorRequest.file_to_generate");
863 target = ::google::protobuf::internal::WireFormatLite::
864 WriteStringToArray(1, this->file_to_generate(i), target);
865 }
866
Austin Schuh40c16522018-10-28 20:27:54 -0700867 cached_has_bits = _has_bits_[0];
Brian Silverman9c614bc2016-02-15 20:20:02 -0500868 // optional string parameter = 2;
Austin Schuh40c16522018-10-28 20:27:54 -0700869 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500870 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -0700871 this->parameter().data(), static_cast<int>(this->parameter().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -0500872 ::google::protobuf::internal::WireFormat::SERIALIZE,
873 "google.protobuf.compiler.CodeGeneratorRequest.parameter");
874 target =
875 ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
876 2, this->parameter(), target);
877 }
878
Austin Schuh40c16522018-10-28 20:27:54 -0700879 // optional .google.protobuf.compiler.Version compiler_version = 3;
880 if (cached_has_bits & 0x00000002u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500881 target = ::google::protobuf::internal::WireFormatLite::
Austin Schuh40c16522018-10-28 20:27:54 -0700882 InternalWriteMessageToArray(
883 3, this->_internal_compiler_version(), deterministic, target);
884 }
885
886 // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
887 for (unsigned int i = 0,
888 n = static_cast<unsigned int>(this->proto_file_size()); i < n; i++) {
889 target = ::google::protobuf::internal::WireFormatLite::
890 InternalWriteMessageToArray(
891 15, this->proto_file(static_cast<int>(i)), deterministic, target);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500892 }
893
894 if (_internal_metadata_.have_unknown_fields()) {
895 target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
Austin Schuh40c16522018-10-28 20:27:54 -0700896 _internal_metadata_.unknown_fields(), target);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500897 }
898 // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.CodeGeneratorRequest)
899 return target;
900}
901
Austin Schuh40c16522018-10-28 20:27:54 -0700902size_t CodeGeneratorRequest::ByteSizeLong() const {
903// @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.CodeGeneratorRequest)
904 size_t total_size = 0;
Brian Silverman9c614bc2016-02-15 20:20:02 -0500905
Austin Schuh40c16522018-10-28 20:27:54 -0700906 if (_internal_metadata_.have_unknown_fields()) {
907 total_size +=
908 ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
909 _internal_metadata_.unknown_fields());
Brian Silverman9c614bc2016-02-15 20:20:02 -0500910 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500911 // repeated string file_to_generate = 1;
Austin Schuh40c16522018-10-28 20:27:54 -0700912 total_size += 1 *
913 ::google::protobuf::internal::FromIntSize(this->file_to_generate_size());
914 for (int i = 0, n = this->file_to_generate_size(); i < n; i++) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500915 total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
916 this->file_to_generate(i));
917 }
918
919 // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
Austin Schuh40c16522018-10-28 20:27:54 -0700920 {
921 unsigned int count = static_cast<unsigned int>(this->proto_file_size());
922 total_size += 1UL * count;
923 for (unsigned int i = 0; i < count; i++) {
924 total_size +=
925 ::google::protobuf::internal::WireFormatLite::MessageSize(
926 this->proto_file(static_cast<int>(i)));
927 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500928 }
929
Austin Schuh40c16522018-10-28 20:27:54 -0700930 if (_has_bits_[0 / 32] & 3u) {
931 // optional string parameter = 2;
932 if (has_parameter()) {
933 total_size += 1 +
934 ::google::protobuf::internal::WireFormatLite::StringSize(
935 this->parameter());
936 }
937
938 // optional .google.protobuf.compiler.Version compiler_version = 3;
939 if (has_compiler_version()) {
940 total_size += 1 +
941 ::google::protobuf::internal::WireFormatLite::MessageSize(
942 *compiler_version_);
943 }
944
Brian Silverman9c614bc2016-02-15 20:20:02 -0500945 }
Austin Schuh40c16522018-10-28 20:27:54 -0700946 int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
947 SetCachedSize(cached_size);
Brian Silverman9c614bc2016-02-15 20:20:02 -0500948 return total_size;
949}
950
951void CodeGeneratorRequest::MergeFrom(const ::google::protobuf::Message& from) {
Austin Schuh40c16522018-10-28 20:27:54 -0700952// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.compiler.CodeGeneratorRequest)
953 GOOGLE_DCHECK_NE(&from, this);
954 const CodeGeneratorRequest* source =
Brian Silverman9c614bc2016-02-15 20:20:02 -0500955 ::google::protobuf::internal::DynamicCastToGenerated<const CodeGeneratorRequest>(
956 &from);
957 if (source == NULL) {
Austin Schuh40c16522018-10-28 20:27:54 -0700958 // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.compiler.CodeGeneratorRequest)
Brian Silverman9c614bc2016-02-15 20:20:02 -0500959 ::google::protobuf::internal::ReflectionOps::Merge(from, this);
960 } else {
Austin Schuh40c16522018-10-28 20:27:54 -0700961 // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.compiler.CodeGeneratorRequest)
Brian Silverman9c614bc2016-02-15 20:20:02 -0500962 MergeFrom(*source);
963 }
964}
965
966void CodeGeneratorRequest::MergeFrom(const CodeGeneratorRequest& from) {
Austin Schuh40c16522018-10-28 20:27:54 -0700967// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.CodeGeneratorRequest)
968 GOOGLE_DCHECK_NE(&from, this);
969 _internal_metadata_.MergeFrom(from._internal_metadata_);
970 ::google::protobuf::uint32 cached_has_bits = 0;
971 (void) cached_has_bits;
972
Brian Silverman9c614bc2016-02-15 20:20:02 -0500973 file_to_generate_.MergeFrom(from.file_to_generate_);
974 proto_file_.MergeFrom(from.proto_file_);
Austin Schuh40c16522018-10-28 20:27:54 -0700975 cached_has_bits = from._has_bits_[0];
976 if (cached_has_bits & 3u) {
977 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -0500978 set_has_parameter();
979 parameter_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.parameter_);
980 }
Austin Schuh40c16522018-10-28 20:27:54 -0700981 if (cached_has_bits & 0x00000002u) {
982 mutable_compiler_version()->::google::protobuf::compiler::Version::MergeFrom(from.compiler_version());
983 }
Brian Silverman9c614bc2016-02-15 20:20:02 -0500984 }
985}
986
987void CodeGeneratorRequest::CopyFrom(const ::google::protobuf::Message& from) {
Austin Schuh40c16522018-10-28 20:27:54 -0700988// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.compiler.CodeGeneratorRequest)
Brian Silverman9c614bc2016-02-15 20:20:02 -0500989 if (&from == this) return;
990 Clear();
991 MergeFrom(from);
992}
993
994void CodeGeneratorRequest::CopyFrom(const CodeGeneratorRequest& from) {
Austin Schuh40c16522018-10-28 20:27:54 -0700995// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.CodeGeneratorRequest)
Brian Silverman9c614bc2016-02-15 20:20:02 -0500996 if (&from == this) return;
997 Clear();
998 MergeFrom(from);
999}
1000
1001bool CodeGeneratorRequest::IsInitialized() const {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001002 if (!::google::protobuf::internal::AllAreInitialized(this->proto_file())) return false;
1003 return true;
1004}
1005
1006void CodeGeneratorRequest::Swap(CodeGeneratorRequest* other) {
1007 if (other == this) return;
1008 InternalSwap(other);
1009}
1010void CodeGeneratorRequest::InternalSwap(CodeGeneratorRequest* other) {
Austin Schuh40c16522018-10-28 20:27:54 -07001011 using std::swap;
1012 file_to_generate_.InternalSwap(CastToBase(&other->file_to_generate_));
1013 CastToBase(&proto_file_)->InternalSwap(CastToBase(&other->proto_file_));
1014 parameter_.Swap(&other->parameter_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
1015 GetArenaNoVirtual());
1016 swap(compiler_version_, other->compiler_version_);
1017 swap(_has_bits_[0], other->_has_bits_[0]);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001018 _internal_metadata_.Swap(&other->_internal_metadata_);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001019}
1020
1021::google::protobuf::Metadata CodeGeneratorRequest::GetMetadata() const {
Austin Schuh40c16522018-10-28 20:27:54 -07001022 protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
1023 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001024}
1025
Brian Silverman9c614bc2016-02-15 20:20:02 -05001026
1027// ===================================================================
1028
Austin Schuh40c16522018-10-28 20:27:54 -07001029void CodeGeneratorResponse_File::InitAsDefaultInstance() {
1030}
Brian Silverman9c614bc2016-02-15 20:20:02 -05001031#if !defined(_MSC_VER) || _MSC_VER >= 1900
1032const int CodeGeneratorResponse_File::kNameFieldNumber;
1033const int CodeGeneratorResponse_File::kInsertionPointFieldNumber;
1034const int CodeGeneratorResponse_File::kContentFieldNumber;
1035#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
1036
1037CodeGeneratorResponse_File::CodeGeneratorResponse_File()
1038 : ::google::protobuf::Message(), _internal_metadata_(NULL) {
Austin Schuh40c16522018-10-28 20:27:54 -07001039 ::google::protobuf::internal::InitSCC(
1040 &protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorResponse_File.base);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001041 SharedCtor();
1042 // @@protoc_insertion_point(constructor:google.protobuf.compiler.CodeGeneratorResponse.File)
1043}
Brian Silverman9c614bc2016-02-15 20:20:02 -05001044CodeGeneratorResponse_File::CodeGeneratorResponse_File(const CodeGeneratorResponse_File& from)
1045 : ::google::protobuf::Message(),
Austin Schuh40c16522018-10-28 20:27:54 -07001046 _internal_metadata_(NULL),
1047 _has_bits_(from._has_bits_) {
1048 _internal_metadata_.MergeFrom(from._internal_metadata_);
1049 name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1050 if (from.has_name()) {
1051 name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
1052 }
1053 insertion_point_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1054 if (from.has_insertion_point()) {
1055 insertion_point_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.insertion_point_);
1056 }
1057 content_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1058 if (from.has_content()) {
1059 content_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.content_);
1060 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001061 // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.CodeGeneratorResponse.File)
1062}
1063
1064void CodeGeneratorResponse_File::SharedCtor() {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001065 name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1066 insertion_point_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1067 content_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
Brian Silverman9c614bc2016-02-15 20:20:02 -05001068}
1069
1070CodeGeneratorResponse_File::~CodeGeneratorResponse_File() {
1071 // @@protoc_insertion_point(destructor:google.protobuf.compiler.CodeGeneratorResponse.File)
1072 SharedDtor();
1073}
1074
1075void CodeGeneratorResponse_File::SharedDtor() {
1076 name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1077 insertion_point_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1078 content_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
Brian Silverman9c614bc2016-02-15 20:20:02 -05001079}
1080
1081void CodeGeneratorResponse_File::SetCachedSize(int size) const {
Austin Schuh40c16522018-10-28 20:27:54 -07001082 _cached_size_.Set(size);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001083}
1084const ::google::protobuf::Descriptor* CodeGeneratorResponse_File::descriptor() {
Austin Schuh40c16522018-10-28 20:27:54 -07001085 ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
1086 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
Brian Silverman9c614bc2016-02-15 20:20:02 -05001087}
1088
1089const CodeGeneratorResponse_File& CodeGeneratorResponse_File::default_instance() {
Austin Schuh40c16522018-10-28 20:27:54 -07001090 ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorResponse_File.base);
1091 return *internal_default_instance();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001092}
1093
Brian Silverman9c614bc2016-02-15 20:20:02 -05001094
1095void CodeGeneratorResponse_File::Clear() {
Austin Schuh40c16522018-10-28 20:27:54 -07001096// @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1097 ::google::protobuf::uint32 cached_has_bits = 0;
1098 // Prevent compiler warnings about cached_has_bits being unused
1099 (void) cached_has_bits;
1100
1101 cached_has_bits = _has_bits_[0];
1102 if (cached_has_bits & 7u) {
1103 if (cached_has_bits & 0x00000001u) {
1104 name_.ClearNonDefaultToEmptyNoArena();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001105 }
Austin Schuh40c16522018-10-28 20:27:54 -07001106 if (cached_has_bits & 0x00000002u) {
1107 insertion_point_.ClearNonDefaultToEmptyNoArena();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001108 }
Austin Schuh40c16522018-10-28 20:27:54 -07001109 if (cached_has_bits & 0x00000004u) {
1110 content_.ClearNonDefaultToEmptyNoArena();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001111 }
1112 }
Austin Schuh40c16522018-10-28 20:27:54 -07001113 _has_bits_.Clear();
1114 _internal_metadata_.Clear();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001115}
1116
1117bool CodeGeneratorResponse_File::MergePartialFromCodedStream(
1118 ::google::protobuf::io::CodedInputStream* input) {
Austin Schuh40c16522018-10-28 20:27:54 -07001119#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
Brian Silverman9c614bc2016-02-15 20:20:02 -05001120 ::google::protobuf::uint32 tag;
1121 // @@protoc_insertion_point(parse_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1122 for (;;) {
Austin Schuh40c16522018-10-28 20:27:54 -07001123 ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001124 tag = p.first;
1125 if (!p.second) goto handle_unusual;
1126 switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
1127 // optional string name = 1;
1128 case 1: {
Austin Schuh40c16522018-10-28 20:27:54 -07001129 if (static_cast< ::google::protobuf::uint8>(tag) ==
1130 static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001131 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
1132 input, this->mutable_name()));
1133 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001134 this->name().data(), static_cast<int>(this->name().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001135 ::google::protobuf::internal::WireFormat::PARSE,
1136 "google.protobuf.compiler.CodeGeneratorResponse.File.name");
1137 } else {
1138 goto handle_unusual;
1139 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001140 break;
1141 }
1142
1143 // optional string insertion_point = 2;
1144 case 2: {
Austin Schuh40c16522018-10-28 20:27:54 -07001145 if (static_cast< ::google::protobuf::uint8>(tag) ==
1146 static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001147 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
1148 input, this->mutable_insertion_point()));
1149 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001150 this->insertion_point().data(), static_cast<int>(this->insertion_point().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001151 ::google::protobuf::internal::WireFormat::PARSE,
1152 "google.protobuf.compiler.CodeGeneratorResponse.File.insertion_point");
1153 } else {
1154 goto handle_unusual;
1155 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001156 break;
1157 }
1158
1159 // optional string content = 15;
1160 case 15: {
Austin Schuh40c16522018-10-28 20:27:54 -07001161 if (static_cast< ::google::protobuf::uint8>(tag) ==
1162 static_cast< ::google::protobuf::uint8>(122u /* 122 & 0xFF */)) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001163 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
1164 input, this->mutable_content()));
1165 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001166 this->content().data(), static_cast<int>(this->content().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001167 ::google::protobuf::internal::WireFormat::PARSE,
1168 "google.protobuf.compiler.CodeGeneratorResponse.File.content");
1169 } else {
1170 goto handle_unusual;
1171 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001172 break;
1173 }
1174
1175 default: {
1176 handle_unusual:
Austin Schuh40c16522018-10-28 20:27:54 -07001177 if (tag == 0) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001178 goto success;
1179 }
1180 DO_(::google::protobuf::internal::WireFormat::SkipField(
Austin Schuh40c16522018-10-28 20:27:54 -07001181 input, tag, _internal_metadata_.mutable_unknown_fields()));
Brian Silverman9c614bc2016-02-15 20:20:02 -05001182 break;
1183 }
1184 }
1185 }
1186success:
1187 // @@protoc_insertion_point(parse_success:google.protobuf.compiler.CodeGeneratorResponse.File)
1188 return true;
1189failure:
1190 // @@protoc_insertion_point(parse_failure:google.protobuf.compiler.CodeGeneratorResponse.File)
1191 return false;
1192#undef DO_
1193}
1194
1195void CodeGeneratorResponse_File::SerializeWithCachedSizes(
1196 ::google::protobuf::io::CodedOutputStream* output) const {
1197 // @@protoc_insertion_point(serialize_start:google.protobuf.compiler.CodeGeneratorResponse.File)
Austin Schuh40c16522018-10-28 20:27:54 -07001198 ::google::protobuf::uint32 cached_has_bits = 0;
1199 (void) cached_has_bits;
1200
1201 cached_has_bits = _has_bits_[0];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001202 // optional string name = 1;
Austin Schuh40c16522018-10-28 20:27:54 -07001203 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001204 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001205 this->name().data(), static_cast<int>(this->name().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001206 ::google::protobuf::internal::WireFormat::SERIALIZE,
1207 "google.protobuf.compiler.CodeGeneratorResponse.File.name");
1208 ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1209 1, this->name(), output);
1210 }
1211
1212 // optional string insertion_point = 2;
Austin Schuh40c16522018-10-28 20:27:54 -07001213 if (cached_has_bits & 0x00000002u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001214 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001215 this->insertion_point().data(), static_cast<int>(this->insertion_point().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001216 ::google::protobuf::internal::WireFormat::SERIALIZE,
1217 "google.protobuf.compiler.CodeGeneratorResponse.File.insertion_point");
1218 ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1219 2, this->insertion_point(), output);
1220 }
1221
1222 // optional string content = 15;
Austin Schuh40c16522018-10-28 20:27:54 -07001223 if (cached_has_bits & 0x00000004u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001224 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001225 this->content().data(), static_cast<int>(this->content().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001226 ::google::protobuf::internal::WireFormat::SERIALIZE,
1227 "google.protobuf.compiler.CodeGeneratorResponse.File.content");
1228 ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1229 15, this->content(), output);
1230 }
1231
1232 if (_internal_metadata_.have_unknown_fields()) {
1233 ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
Austin Schuh40c16522018-10-28 20:27:54 -07001234 _internal_metadata_.unknown_fields(), output);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001235 }
1236 // @@protoc_insertion_point(serialize_end:google.protobuf.compiler.CodeGeneratorResponse.File)
1237}
1238
Austin Schuh40c16522018-10-28 20:27:54 -07001239::google::protobuf::uint8* CodeGeneratorResponse_File::InternalSerializeWithCachedSizesToArray(
1240 bool deterministic, ::google::protobuf::uint8* target) const {
1241 (void)deterministic; // Unused
Brian Silverman9c614bc2016-02-15 20:20:02 -05001242 // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.CodeGeneratorResponse.File)
Austin Schuh40c16522018-10-28 20:27:54 -07001243 ::google::protobuf::uint32 cached_has_bits = 0;
1244 (void) cached_has_bits;
1245
1246 cached_has_bits = _has_bits_[0];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001247 // optional string name = 1;
Austin Schuh40c16522018-10-28 20:27:54 -07001248 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001249 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001250 this->name().data(), static_cast<int>(this->name().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001251 ::google::protobuf::internal::WireFormat::SERIALIZE,
1252 "google.protobuf.compiler.CodeGeneratorResponse.File.name");
1253 target =
1254 ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1255 1, this->name(), target);
1256 }
1257
1258 // optional string insertion_point = 2;
Austin Schuh40c16522018-10-28 20:27:54 -07001259 if (cached_has_bits & 0x00000002u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001260 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001261 this->insertion_point().data(), static_cast<int>(this->insertion_point().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001262 ::google::protobuf::internal::WireFormat::SERIALIZE,
1263 "google.protobuf.compiler.CodeGeneratorResponse.File.insertion_point");
1264 target =
1265 ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1266 2, this->insertion_point(), target);
1267 }
1268
1269 // optional string content = 15;
Austin Schuh40c16522018-10-28 20:27:54 -07001270 if (cached_has_bits & 0x00000004u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001271 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001272 this->content().data(), static_cast<int>(this->content().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001273 ::google::protobuf::internal::WireFormat::SERIALIZE,
1274 "google.protobuf.compiler.CodeGeneratorResponse.File.content");
1275 target =
1276 ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1277 15, this->content(), target);
1278 }
1279
1280 if (_internal_metadata_.have_unknown_fields()) {
1281 target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
Austin Schuh40c16522018-10-28 20:27:54 -07001282 _internal_metadata_.unknown_fields(), target);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001283 }
1284 // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.CodeGeneratorResponse.File)
1285 return target;
1286}
1287
Austin Schuh40c16522018-10-28 20:27:54 -07001288size_t CodeGeneratorResponse_File::ByteSizeLong() const {
1289// @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1290 size_t total_size = 0;
Brian Silverman9c614bc2016-02-15 20:20:02 -05001291
Austin Schuh40c16522018-10-28 20:27:54 -07001292 if (_internal_metadata_.have_unknown_fields()) {
1293 total_size +=
1294 ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
1295 _internal_metadata_.unknown_fields());
1296 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001297 if (_has_bits_[0 / 32] & 7u) {
1298 // optional string name = 1;
1299 if (has_name()) {
1300 total_size += 1 +
1301 ::google::protobuf::internal::WireFormatLite::StringSize(
1302 this->name());
1303 }
1304
1305 // optional string insertion_point = 2;
1306 if (has_insertion_point()) {
1307 total_size += 1 +
1308 ::google::protobuf::internal::WireFormatLite::StringSize(
1309 this->insertion_point());
1310 }
1311
1312 // optional string content = 15;
1313 if (has_content()) {
1314 total_size += 1 +
1315 ::google::protobuf::internal::WireFormatLite::StringSize(
1316 this->content());
1317 }
1318
1319 }
Austin Schuh40c16522018-10-28 20:27:54 -07001320 int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
1321 SetCachedSize(cached_size);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001322 return total_size;
1323}
1324
1325void CodeGeneratorResponse_File::MergeFrom(const ::google::protobuf::Message& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001326// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1327 GOOGLE_DCHECK_NE(&from, this);
1328 const CodeGeneratorResponse_File* source =
Brian Silverman9c614bc2016-02-15 20:20:02 -05001329 ::google::protobuf::internal::DynamicCastToGenerated<const CodeGeneratorResponse_File>(
1330 &from);
1331 if (source == NULL) {
Austin Schuh40c16522018-10-28 20:27:54 -07001332 // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.compiler.CodeGeneratorResponse.File)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001333 ::google::protobuf::internal::ReflectionOps::Merge(from, this);
1334 } else {
Austin Schuh40c16522018-10-28 20:27:54 -07001335 // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.compiler.CodeGeneratorResponse.File)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001336 MergeFrom(*source);
1337 }
1338}
1339
1340void CodeGeneratorResponse_File::MergeFrom(const CodeGeneratorResponse_File& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001341// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1342 GOOGLE_DCHECK_NE(&from, this);
1343 _internal_metadata_.MergeFrom(from._internal_metadata_);
1344 ::google::protobuf::uint32 cached_has_bits = 0;
1345 (void) cached_has_bits;
1346
1347 cached_has_bits = from._has_bits_[0];
1348 if (cached_has_bits & 7u) {
1349 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001350 set_has_name();
1351 name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
1352 }
Austin Schuh40c16522018-10-28 20:27:54 -07001353 if (cached_has_bits & 0x00000002u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001354 set_has_insertion_point();
1355 insertion_point_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.insertion_point_);
1356 }
Austin Schuh40c16522018-10-28 20:27:54 -07001357 if (cached_has_bits & 0x00000004u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001358 set_has_content();
1359 content_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.content_);
1360 }
1361 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001362}
1363
1364void CodeGeneratorResponse_File::CopyFrom(const ::google::protobuf::Message& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001365// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.compiler.CodeGeneratorResponse.File)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001366 if (&from == this) return;
1367 Clear();
1368 MergeFrom(from);
1369}
1370
1371void CodeGeneratorResponse_File::CopyFrom(const CodeGeneratorResponse_File& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001372// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.CodeGeneratorResponse.File)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001373 if (&from == this) return;
1374 Clear();
1375 MergeFrom(from);
1376}
1377
1378bool CodeGeneratorResponse_File::IsInitialized() const {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001379 return true;
1380}
1381
1382void CodeGeneratorResponse_File::Swap(CodeGeneratorResponse_File* other) {
1383 if (other == this) return;
1384 InternalSwap(other);
1385}
1386void CodeGeneratorResponse_File::InternalSwap(CodeGeneratorResponse_File* other) {
Austin Schuh40c16522018-10-28 20:27:54 -07001387 using std::swap;
1388 name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
1389 GetArenaNoVirtual());
1390 insertion_point_.Swap(&other->insertion_point_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
1391 GetArenaNoVirtual());
1392 content_.Swap(&other->content_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
1393 GetArenaNoVirtual());
1394 swap(_has_bits_[0], other->_has_bits_[0]);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001395 _internal_metadata_.Swap(&other->_internal_metadata_);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001396}
1397
1398::google::protobuf::Metadata CodeGeneratorResponse_File::GetMetadata() const {
Austin Schuh40c16522018-10-28 20:27:54 -07001399 protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
1400 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001401}
1402
1403
Austin Schuh40c16522018-10-28 20:27:54 -07001404// ===================================================================
Brian Silverman9c614bc2016-02-15 20:20:02 -05001405
Austin Schuh40c16522018-10-28 20:27:54 -07001406void CodeGeneratorResponse::InitAsDefaultInstance() {
1407}
Brian Silverman9c614bc2016-02-15 20:20:02 -05001408#if !defined(_MSC_VER) || _MSC_VER >= 1900
1409const int CodeGeneratorResponse::kErrorFieldNumber;
1410const int CodeGeneratorResponse::kFileFieldNumber;
1411#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
1412
1413CodeGeneratorResponse::CodeGeneratorResponse()
1414 : ::google::protobuf::Message(), _internal_metadata_(NULL) {
Austin Schuh40c16522018-10-28 20:27:54 -07001415 ::google::protobuf::internal::InitSCC(
1416 &protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorResponse.base);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001417 SharedCtor();
1418 // @@protoc_insertion_point(constructor:google.protobuf.compiler.CodeGeneratorResponse)
1419}
Brian Silverman9c614bc2016-02-15 20:20:02 -05001420CodeGeneratorResponse::CodeGeneratorResponse(const CodeGeneratorResponse& from)
1421 : ::google::protobuf::Message(),
Austin Schuh40c16522018-10-28 20:27:54 -07001422 _internal_metadata_(NULL),
1423 _has_bits_(from._has_bits_),
1424 file_(from.file_) {
1425 _internal_metadata_.MergeFrom(from._internal_metadata_);
1426 error_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
1427 if (from.has_error()) {
1428 error_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.error_);
1429 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001430 // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.CodeGeneratorResponse)
1431}
1432
1433void CodeGeneratorResponse::SharedCtor() {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001434 error_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
Brian Silverman9c614bc2016-02-15 20:20:02 -05001435}
1436
1437CodeGeneratorResponse::~CodeGeneratorResponse() {
1438 // @@protoc_insertion_point(destructor:google.protobuf.compiler.CodeGeneratorResponse)
1439 SharedDtor();
1440}
1441
1442void CodeGeneratorResponse::SharedDtor() {
1443 error_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
Brian Silverman9c614bc2016-02-15 20:20:02 -05001444}
1445
1446void CodeGeneratorResponse::SetCachedSize(int size) const {
Austin Schuh40c16522018-10-28 20:27:54 -07001447 _cached_size_.Set(size);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001448}
1449const ::google::protobuf::Descriptor* CodeGeneratorResponse::descriptor() {
Austin Schuh40c16522018-10-28 20:27:54 -07001450 ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
1451 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
Brian Silverman9c614bc2016-02-15 20:20:02 -05001452}
1453
1454const CodeGeneratorResponse& CodeGeneratorResponse::default_instance() {
Austin Schuh40c16522018-10-28 20:27:54 -07001455 ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::scc_info_CodeGeneratorResponse.base);
1456 return *internal_default_instance();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001457}
1458
Brian Silverman9c614bc2016-02-15 20:20:02 -05001459
1460void CodeGeneratorResponse::Clear() {
Austin Schuh40c16522018-10-28 20:27:54 -07001461// @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorResponse)
1462 ::google::protobuf::uint32 cached_has_bits = 0;
1463 // Prevent compiler warnings about cached_has_bits being unused
1464 (void) cached_has_bits;
1465
Brian Silverman9c614bc2016-02-15 20:20:02 -05001466 file_.Clear();
Austin Schuh40c16522018-10-28 20:27:54 -07001467 cached_has_bits = _has_bits_[0];
1468 if (cached_has_bits & 0x00000001u) {
1469 error_.ClearNonDefaultToEmptyNoArena();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001470 }
Austin Schuh40c16522018-10-28 20:27:54 -07001471 _has_bits_.Clear();
1472 _internal_metadata_.Clear();
Brian Silverman9c614bc2016-02-15 20:20:02 -05001473}
1474
1475bool CodeGeneratorResponse::MergePartialFromCodedStream(
1476 ::google::protobuf::io::CodedInputStream* input) {
Austin Schuh40c16522018-10-28 20:27:54 -07001477#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
Brian Silverman9c614bc2016-02-15 20:20:02 -05001478 ::google::protobuf::uint32 tag;
1479 // @@protoc_insertion_point(parse_start:google.protobuf.compiler.CodeGeneratorResponse)
1480 for (;;) {
Austin Schuh40c16522018-10-28 20:27:54 -07001481 ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001482 tag = p.first;
1483 if (!p.second) goto handle_unusual;
1484 switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
1485 // optional string error = 1;
1486 case 1: {
Austin Schuh40c16522018-10-28 20:27:54 -07001487 if (static_cast< ::google::protobuf::uint8>(tag) ==
1488 static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001489 DO_(::google::protobuf::internal::WireFormatLite::ReadString(
1490 input, this->mutable_error()));
1491 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001492 this->error().data(), static_cast<int>(this->error().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001493 ::google::protobuf::internal::WireFormat::PARSE,
1494 "google.protobuf.compiler.CodeGeneratorResponse.error");
1495 } else {
1496 goto handle_unusual;
1497 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001498 break;
1499 }
1500
1501 // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
1502 case 15: {
Austin Schuh40c16522018-10-28 20:27:54 -07001503 if (static_cast< ::google::protobuf::uint8>(tag) ==
1504 static_cast< ::google::protobuf::uint8>(122u /* 122 & 0xFF */)) {
1505 DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
Brian Silverman9c614bc2016-02-15 20:20:02 -05001506 input, add_file()));
1507 } else {
1508 goto handle_unusual;
1509 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001510 break;
1511 }
1512
1513 default: {
1514 handle_unusual:
Austin Schuh40c16522018-10-28 20:27:54 -07001515 if (tag == 0) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001516 goto success;
1517 }
1518 DO_(::google::protobuf::internal::WireFormat::SkipField(
Austin Schuh40c16522018-10-28 20:27:54 -07001519 input, tag, _internal_metadata_.mutable_unknown_fields()));
Brian Silverman9c614bc2016-02-15 20:20:02 -05001520 break;
1521 }
1522 }
1523 }
1524success:
1525 // @@protoc_insertion_point(parse_success:google.protobuf.compiler.CodeGeneratorResponse)
1526 return true;
1527failure:
1528 // @@protoc_insertion_point(parse_failure:google.protobuf.compiler.CodeGeneratorResponse)
1529 return false;
1530#undef DO_
1531}
1532
1533void CodeGeneratorResponse::SerializeWithCachedSizes(
1534 ::google::protobuf::io::CodedOutputStream* output) const {
1535 // @@protoc_insertion_point(serialize_start:google.protobuf.compiler.CodeGeneratorResponse)
Austin Schuh40c16522018-10-28 20:27:54 -07001536 ::google::protobuf::uint32 cached_has_bits = 0;
1537 (void) cached_has_bits;
1538
1539 cached_has_bits = _has_bits_[0];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001540 // optional string error = 1;
Austin Schuh40c16522018-10-28 20:27:54 -07001541 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001542 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001543 this->error().data(), static_cast<int>(this->error().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001544 ::google::protobuf::internal::WireFormat::SERIALIZE,
1545 "google.protobuf.compiler.CodeGeneratorResponse.error");
1546 ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1547 1, this->error(), output);
1548 }
1549
1550 // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
Austin Schuh40c16522018-10-28 20:27:54 -07001551 for (unsigned int i = 0,
1552 n = static_cast<unsigned int>(this->file_size()); i < n; i++) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001553 ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
Austin Schuh40c16522018-10-28 20:27:54 -07001554 15,
1555 this->file(static_cast<int>(i)),
1556 output);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001557 }
1558
1559 if (_internal_metadata_.have_unknown_fields()) {
1560 ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
Austin Schuh40c16522018-10-28 20:27:54 -07001561 _internal_metadata_.unknown_fields(), output);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001562 }
1563 // @@protoc_insertion_point(serialize_end:google.protobuf.compiler.CodeGeneratorResponse)
1564}
1565
Austin Schuh40c16522018-10-28 20:27:54 -07001566::google::protobuf::uint8* CodeGeneratorResponse::InternalSerializeWithCachedSizesToArray(
1567 bool deterministic, ::google::protobuf::uint8* target) const {
1568 (void)deterministic; // Unused
Brian Silverman9c614bc2016-02-15 20:20:02 -05001569 // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.CodeGeneratorResponse)
Austin Schuh40c16522018-10-28 20:27:54 -07001570 ::google::protobuf::uint32 cached_has_bits = 0;
1571 (void) cached_has_bits;
1572
1573 cached_has_bits = _has_bits_[0];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001574 // optional string error = 1;
Austin Schuh40c16522018-10-28 20:27:54 -07001575 if (cached_has_bits & 0x00000001u) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001576 ::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
Austin Schuh40c16522018-10-28 20:27:54 -07001577 this->error().data(), static_cast<int>(this->error().length()),
Brian Silverman9c614bc2016-02-15 20:20:02 -05001578 ::google::protobuf::internal::WireFormat::SERIALIZE,
1579 "google.protobuf.compiler.CodeGeneratorResponse.error");
1580 target =
1581 ::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1582 1, this->error(), target);
1583 }
1584
1585 // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
Austin Schuh40c16522018-10-28 20:27:54 -07001586 for (unsigned int i = 0,
1587 n = static_cast<unsigned int>(this->file_size()); i < n; i++) {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001588 target = ::google::protobuf::internal::WireFormatLite::
Austin Schuh40c16522018-10-28 20:27:54 -07001589 InternalWriteMessageToArray(
1590 15, this->file(static_cast<int>(i)), deterministic, target);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001591 }
1592
1593 if (_internal_metadata_.have_unknown_fields()) {
1594 target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
Austin Schuh40c16522018-10-28 20:27:54 -07001595 _internal_metadata_.unknown_fields(), target);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001596 }
1597 // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.CodeGeneratorResponse)
1598 return target;
1599}
1600
Austin Schuh40c16522018-10-28 20:27:54 -07001601size_t CodeGeneratorResponse::ByteSizeLong() const {
1602// @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.CodeGeneratorResponse)
1603 size_t total_size = 0;
1604
1605 if (_internal_metadata_.have_unknown_fields()) {
1606 total_size +=
1607 ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
1608 _internal_metadata_.unknown_fields());
1609 }
1610 // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
1611 {
1612 unsigned int count = static_cast<unsigned int>(this->file_size());
1613 total_size += 1UL * count;
1614 for (unsigned int i = 0; i < count; i++) {
1615 total_size +=
1616 ::google::protobuf::internal::WireFormatLite::MessageSize(
1617 this->file(static_cast<int>(i)));
1618 }
1619 }
Brian Silverman9c614bc2016-02-15 20:20:02 -05001620
1621 // optional string error = 1;
1622 if (has_error()) {
1623 total_size += 1 +
1624 ::google::protobuf::internal::WireFormatLite::StringSize(
1625 this->error());
1626 }
1627
Austin Schuh40c16522018-10-28 20:27:54 -07001628 int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
1629 SetCachedSize(cached_size);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001630 return total_size;
1631}
1632
1633void CodeGeneratorResponse::MergeFrom(const ::google::protobuf::Message& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001634// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.compiler.CodeGeneratorResponse)
1635 GOOGLE_DCHECK_NE(&from, this);
1636 const CodeGeneratorResponse* source =
Brian Silverman9c614bc2016-02-15 20:20:02 -05001637 ::google::protobuf::internal::DynamicCastToGenerated<const CodeGeneratorResponse>(
1638 &from);
1639 if (source == NULL) {
Austin Schuh40c16522018-10-28 20:27:54 -07001640 // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.compiler.CodeGeneratorResponse)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001641 ::google::protobuf::internal::ReflectionOps::Merge(from, this);
1642 } else {
Austin Schuh40c16522018-10-28 20:27:54 -07001643 // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.compiler.CodeGeneratorResponse)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001644 MergeFrom(*source);
1645 }
1646}
1647
1648void CodeGeneratorResponse::MergeFrom(const CodeGeneratorResponse& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001649// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.CodeGeneratorResponse)
1650 GOOGLE_DCHECK_NE(&from, this);
1651 _internal_metadata_.MergeFrom(from._internal_metadata_);
1652 ::google::protobuf::uint32 cached_has_bits = 0;
1653 (void) cached_has_bits;
1654
Brian Silverman9c614bc2016-02-15 20:20:02 -05001655 file_.MergeFrom(from.file_);
Austin Schuh40c16522018-10-28 20:27:54 -07001656 if (from.has_error()) {
1657 set_has_error();
1658 error_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.error_);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001659 }
1660}
1661
1662void CodeGeneratorResponse::CopyFrom(const ::google::protobuf::Message& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001663// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.compiler.CodeGeneratorResponse)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001664 if (&from == this) return;
1665 Clear();
1666 MergeFrom(from);
1667}
1668
1669void CodeGeneratorResponse::CopyFrom(const CodeGeneratorResponse& from) {
Austin Schuh40c16522018-10-28 20:27:54 -07001670// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.CodeGeneratorResponse)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001671 if (&from == this) return;
1672 Clear();
1673 MergeFrom(from);
1674}
1675
1676bool CodeGeneratorResponse::IsInitialized() const {
Brian Silverman9c614bc2016-02-15 20:20:02 -05001677 return true;
1678}
1679
1680void CodeGeneratorResponse::Swap(CodeGeneratorResponse* other) {
1681 if (other == this) return;
1682 InternalSwap(other);
1683}
1684void CodeGeneratorResponse::InternalSwap(CodeGeneratorResponse* other) {
Austin Schuh40c16522018-10-28 20:27:54 -07001685 using std::swap;
1686 CastToBase(&file_)->InternalSwap(CastToBase(&other->file_));
1687 error_.Swap(&other->error_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
1688 GetArenaNoVirtual());
1689 swap(_has_bits_[0], other->_has_bits_[0]);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001690 _internal_metadata_.Swap(&other->_internal_metadata_);
Brian Silverman9c614bc2016-02-15 20:20:02 -05001691}
1692
1693::google::protobuf::Metadata CodeGeneratorResponse::GetMetadata() const {
Austin Schuh40c16522018-10-28 20:27:54 -07001694 protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::protobuf_AssignDescriptorsOnce();
1695 return ::protobuf_google_2fprotobuf_2fcompiler_2fplugin_2eproto::file_level_metadata[kIndexInFileMessages];
Brian Silverman9c614bc2016-02-15 20:20:02 -05001696}
1697
Brian Silverman9c614bc2016-02-15 20:20:02 -05001698
1699// @@protoc_insertion_point(namespace_scope)
Brian Silverman9c614bc2016-02-15 20:20:02 -05001700} // namespace compiler
1701} // namespace protobuf
1702} // namespace google
Austin Schuh40c16522018-10-28 20:27:54 -07001703namespace google {
1704namespace protobuf {
1705template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::compiler::Version* Arena::CreateMaybeMessage< ::google::protobuf::compiler::Version >(Arena* arena) {
1706 return Arena::CreateInternal< ::google::protobuf::compiler::Version >(arena);
1707}
1708template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::compiler::CodeGeneratorRequest* Arena::CreateMaybeMessage< ::google::protobuf::compiler::CodeGeneratorRequest >(Arena* arena) {
1709 return Arena::CreateInternal< ::google::protobuf::compiler::CodeGeneratorRequest >(arena);
1710}
1711template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::compiler::CodeGeneratorResponse_File* Arena::CreateMaybeMessage< ::google::protobuf::compiler::CodeGeneratorResponse_File >(Arena* arena) {
1712 return Arena::CreateInternal< ::google::protobuf::compiler::CodeGeneratorResponse_File >(arena);
1713}
1714template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::compiler::CodeGeneratorResponse* Arena::CreateMaybeMessage< ::google::protobuf::compiler::CodeGeneratorResponse >(Arena* arena) {
1715 return Arena::CreateInternal< ::google::protobuf::compiler::CodeGeneratorResponse >(arena);
1716}
1717} // namespace protobuf
1718} // namespace google
Brian Silverman9c614bc2016-02-15 20:20:02 -05001719
1720// @@protoc_insertion_point(global_scope)