Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Tetragramm
GitHub Repository: Tetragramm/opencv
Path: blob/master/modules/dnn/misc/tensorflow/versions.pb.cc
16358 views
1
// Generated by the protocol buffer compiler. DO NOT EDIT!
2
// source: versions.proto
3
4
#include "versions.pb.h"
5
6
#include <algorithm>
7
8
#include <google/protobuf/stubs/common.h>
9
#include <google/protobuf/stubs/port.h>
10
#include <google/protobuf/stubs/once.h>
11
#include <google/protobuf/io/coded_stream.h>
12
#include <google/protobuf/wire_format_lite_inl.h>
13
#include <google/protobuf/descriptor.h>
14
#include <google/protobuf/generated_message_reflection.h>
15
#include <google/protobuf/reflection_ops.h>
16
#include <google/protobuf/wire_format.h>
17
// This is a temporary google only hack
18
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
19
#include "third_party/protobuf/version.h"
20
#endif
21
// @@protoc_insertion_point(includes)
22
namespace opencv_tensorflow {
23
class VersionDefDefaultTypeInternal {
24
public:
25
::google::protobuf::internal::ExplicitlyConstructed<VersionDef>
26
_instance;
27
} _VersionDef_default_instance_;
28
} // namespace opencv_tensorflow
29
namespace protobuf_versions_2eproto {
30
void InitDefaultsVersionDefImpl() {
31
GOOGLE_PROTOBUF_VERIFY_VERSION;
32
33
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
34
::google::protobuf::internal::InitProtobufDefaultsForceUnique();
35
#else
36
::google::protobuf::internal::InitProtobufDefaults();
37
#endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
38
{
39
void* ptr = &::opencv_tensorflow::_VersionDef_default_instance_;
40
new (ptr) ::opencv_tensorflow::VersionDef();
41
::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
42
}
43
::opencv_tensorflow::VersionDef::InitAsDefaultInstance();
44
}
45
46
void InitDefaultsVersionDef() {
47
static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
48
::google::protobuf::GoogleOnceInit(&once, &InitDefaultsVersionDefImpl);
49
}
50
51
::google::protobuf::Metadata file_level_metadata[1];
52
53
const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
54
~0u, // no _has_bits_
55
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::opencv_tensorflow::VersionDef, _internal_metadata_),
56
~0u, // no _extensions_
57
~0u, // no _oneof_case_
58
~0u, // no _weak_field_map_
59
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::opencv_tensorflow::VersionDef, producer_),
60
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::opencv_tensorflow::VersionDef, min_consumer_),
61
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::opencv_tensorflow::VersionDef, bad_consumers_),
62
};
63
static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
64
{ 0, -1, sizeof(::opencv_tensorflow::VersionDef)},
65
};
66
67
static ::google::protobuf::Message const * const file_default_instances[] = {
68
reinterpret_cast<const ::google::protobuf::Message*>(&::opencv_tensorflow::_VersionDef_default_instance_),
69
};
70
71
void protobuf_AssignDescriptors() {
72
AddDescriptors();
73
::google::protobuf::MessageFactory* factory = NULL;
74
AssignDescriptors(
75
"versions.proto", schemas, file_default_instances, TableStruct::offsets, factory,
76
file_level_metadata, NULL, NULL);
77
}
78
79
void protobuf_AssignDescriptorsOnce() {
80
static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
81
::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors);
82
}
83
84
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
85
void protobuf_RegisterTypes(const ::std::string&) {
86
protobuf_AssignDescriptorsOnce();
87
::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 1);
88
}
89
90
void AddDescriptorsImpl() {
91
InitDefaults();
92
static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
93
"\n\016versions.proto\022\021opencv_tensorflow\"K\n\nV"
94
"ersionDef\022\020\n\010producer\030\001 \001(\005\022\024\n\014min_consu"
95
"mer\030\002 \001(\005\022\025\n\rbad_consumers\030\003 \003(\005B/\n\030org."
96
"tensorflow.frameworkB\016VersionsProtosP\001\370\001"
97
"\001b\006proto3"
98
};
99
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
100
descriptor, 169);
101
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
102
"versions.proto", &protobuf_RegisterTypes);
103
}
104
105
void AddDescriptors() {
106
static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
107
::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
108
}
109
// Force AddDescriptors() to be called at dynamic initialization time.
110
struct StaticDescriptorInitializer {
111
StaticDescriptorInitializer() {
112
AddDescriptors();
113
}
114
} static_descriptor_initializer;
115
} // namespace protobuf_versions_2eproto
116
namespace opencv_tensorflow {
117
118
// ===================================================================
119
120
void VersionDef::InitAsDefaultInstance() {
121
}
122
#if !defined(_MSC_VER) || _MSC_VER >= 1900
123
const int VersionDef::kProducerFieldNumber;
124
const int VersionDef::kMinConsumerFieldNumber;
125
const int VersionDef::kBadConsumersFieldNumber;
126
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
127
128
VersionDef::VersionDef()
129
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
130
if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
131
::protobuf_versions_2eproto::InitDefaultsVersionDef();
132
}
133
SharedCtor();
134
// @@protoc_insertion_point(constructor:opencv_tensorflow.VersionDef)
135
}
136
VersionDef::VersionDef(::google::protobuf::Arena* arena)
137
: ::google::protobuf::Message(),
138
_internal_metadata_(arena),
139
bad_consumers_(arena) {
140
::protobuf_versions_2eproto::InitDefaultsVersionDef();
141
SharedCtor();
142
RegisterArenaDtor(arena);
143
// @@protoc_insertion_point(arena_constructor:opencv_tensorflow.VersionDef)
144
}
145
VersionDef::VersionDef(const VersionDef& from)
146
: ::google::protobuf::Message(),
147
_internal_metadata_(NULL),
148
bad_consumers_(from.bad_consumers_),
149
_cached_size_(0) {
150
_internal_metadata_.MergeFrom(from._internal_metadata_);
151
::memcpy(&producer_, &from.producer_,
152
static_cast<size_t>(reinterpret_cast<char*>(&min_consumer_) -
153
reinterpret_cast<char*>(&producer_)) + sizeof(min_consumer_));
154
// @@protoc_insertion_point(copy_constructor:opencv_tensorflow.VersionDef)
155
}
156
157
void VersionDef::SharedCtor() {
158
::memset(&producer_, 0, static_cast<size_t>(
159
reinterpret_cast<char*>(&min_consumer_) -
160
reinterpret_cast<char*>(&producer_)) + sizeof(min_consumer_));
161
_cached_size_ = 0;
162
}
163
164
VersionDef::~VersionDef() {
165
// @@protoc_insertion_point(destructor:opencv_tensorflow.VersionDef)
166
SharedDtor();
167
}
168
169
void VersionDef::SharedDtor() {
170
GOOGLE_DCHECK(GetArenaNoVirtual() == NULL);
171
}
172
173
void VersionDef::ArenaDtor(void* object) {
174
VersionDef* _this = reinterpret_cast< VersionDef* >(object);
175
(void)_this;
176
}
177
void VersionDef::RegisterArenaDtor(::google::protobuf::Arena* arena) {
178
}
179
void VersionDef::SetCachedSize(int size) const {
180
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
181
_cached_size_ = size;
182
GOOGLE_SAFE_CONCURRENT_WRITES_END();
183
}
184
const ::google::protobuf::Descriptor* VersionDef::descriptor() {
185
::protobuf_versions_2eproto::protobuf_AssignDescriptorsOnce();
186
return ::protobuf_versions_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
187
}
188
189
const VersionDef& VersionDef::default_instance() {
190
::protobuf_versions_2eproto::InitDefaultsVersionDef();
191
return *internal_default_instance();
192
}
193
194
VersionDef* VersionDef::New(::google::protobuf::Arena* arena) const {
195
return ::google::protobuf::Arena::CreateMessage<VersionDef>(arena);
196
}
197
198
void VersionDef::Clear() {
199
// @@protoc_insertion_point(message_clear_start:opencv_tensorflow.VersionDef)
200
::google::protobuf::uint32 cached_has_bits = 0;
201
// Prevent compiler warnings about cached_has_bits being unused
202
(void) cached_has_bits;
203
204
bad_consumers_.Clear();
205
::memset(&producer_, 0, static_cast<size_t>(
206
reinterpret_cast<char*>(&min_consumer_) -
207
reinterpret_cast<char*>(&producer_)) + sizeof(min_consumer_));
208
_internal_metadata_.Clear();
209
}
210
211
bool VersionDef::MergePartialFromCodedStream(
212
::google::protobuf::io::CodedInputStream* input) {
213
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
214
::google::protobuf::uint32 tag;
215
// @@protoc_insertion_point(parse_start:opencv_tensorflow.VersionDef)
216
for (;;) {
217
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
218
tag = p.first;
219
if (!p.second) goto handle_unusual;
220
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
221
// int32 producer = 1;
222
case 1: {
223
if (static_cast< ::google::protobuf::uint8>(tag) ==
224
static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
225
226
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
227
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
228
input, &producer_)));
229
} else {
230
goto handle_unusual;
231
}
232
break;
233
}
234
235
// int32 min_consumer = 2;
236
case 2: {
237
if (static_cast< ::google::protobuf::uint8>(tag) ==
238
static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
239
240
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
241
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
242
input, &min_consumer_)));
243
} else {
244
goto handle_unusual;
245
}
246
break;
247
}
248
249
// repeated int32 bad_consumers = 3;
250
case 3: {
251
if (static_cast< ::google::protobuf::uint8>(tag) ==
252
static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
253
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
254
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
255
input, this->mutable_bad_consumers())));
256
} else if (
257
static_cast< ::google::protobuf::uint8>(tag) ==
258
static_cast< ::google::protobuf::uint8>(24u /* 24 & 0xFF */)) {
259
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
260
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
261
1, 26u, input, this->mutable_bad_consumers())));
262
} else {
263
goto handle_unusual;
264
}
265
break;
266
}
267
268
default: {
269
handle_unusual:
270
if (tag == 0) {
271
goto success;
272
}
273
DO_(::google::protobuf::internal::WireFormat::SkipField(
274
input, tag, _internal_metadata_.mutable_unknown_fields()));
275
break;
276
}
277
}
278
}
279
success:
280
// @@protoc_insertion_point(parse_success:opencv_tensorflow.VersionDef)
281
return true;
282
failure:
283
// @@protoc_insertion_point(parse_failure:opencv_tensorflow.VersionDef)
284
return false;
285
#undef DO_
286
}
287
288
void VersionDef::SerializeWithCachedSizes(
289
::google::protobuf::io::CodedOutputStream* output) const {
290
// @@protoc_insertion_point(serialize_start:opencv_tensorflow.VersionDef)
291
::google::protobuf::uint32 cached_has_bits = 0;
292
(void) cached_has_bits;
293
294
// int32 producer = 1;
295
if (this->producer() != 0) {
296
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->producer(), output);
297
}
298
299
// int32 min_consumer = 2;
300
if (this->min_consumer() != 0) {
301
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->min_consumer(), output);
302
}
303
304
// repeated int32 bad_consumers = 3;
305
if (this->bad_consumers_size() > 0) {
306
::google::protobuf::internal::WireFormatLite::WriteTag(3, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
307
output->WriteVarint32(static_cast< ::google::protobuf::uint32>(
308
_bad_consumers_cached_byte_size_));
309
}
310
for (int i = 0, n = this->bad_consumers_size(); i < n; i++) {
311
::google::protobuf::internal::WireFormatLite::WriteInt32NoTag(
312
this->bad_consumers(i), output);
313
}
314
315
if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
316
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
317
(::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output);
318
}
319
// @@protoc_insertion_point(serialize_end:opencv_tensorflow.VersionDef)
320
}
321
322
::google::protobuf::uint8* VersionDef::InternalSerializeWithCachedSizesToArray(
323
bool deterministic, ::google::protobuf::uint8* target) const {
324
(void)deterministic; // Unused
325
// @@protoc_insertion_point(serialize_to_array_start:opencv_tensorflow.VersionDef)
326
::google::protobuf::uint32 cached_has_bits = 0;
327
(void) cached_has_bits;
328
329
// int32 producer = 1;
330
if (this->producer() != 0) {
331
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->producer(), target);
332
}
333
334
// int32 min_consumer = 2;
335
if (this->min_consumer() != 0) {
336
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->min_consumer(), target);
337
}
338
339
// repeated int32 bad_consumers = 3;
340
if (this->bad_consumers_size() > 0) {
341
target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
342
3,
343
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
344
target);
345
target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
346
static_cast< ::google::protobuf::int32>(
347
_bad_consumers_cached_byte_size_), target);
348
target = ::google::protobuf::internal::WireFormatLite::
349
WriteInt32NoTagToArray(this->bad_consumers_, target);
350
}
351
352
if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
353
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
354
(::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target);
355
}
356
// @@protoc_insertion_point(serialize_to_array_end:opencv_tensorflow.VersionDef)
357
return target;
358
}
359
360
size_t VersionDef::ByteSizeLong() const {
361
// @@protoc_insertion_point(message_byte_size_start:opencv_tensorflow.VersionDef)
362
size_t total_size = 0;
363
364
if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
365
total_size +=
366
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
367
(::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()));
368
}
369
// repeated int32 bad_consumers = 3;
370
{
371
size_t data_size = ::google::protobuf::internal::WireFormatLite::
372
Int32Size(this->bad_consumers_);
373
if (data_size > 0) {
374
total_size += 1 +
375
::google::protobuf::internal::WireFormatLite::Int32Size(
376
static_cast< ::google::protobuf::int32>(data_size));
377
}
378
int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
379
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
380
_bad_consumers_cached_byte_size_ = cached_size;
381
GOOGLE_SAFE_CONCURRENT_WRITES_END();
382
total_size += data_size;
383
}
384
385
// int32 producer = 1;
386
if (this->producer() != 0) {
387
total_size += 1 +
388
::google::protobuf::internal::WireFormatLite::Int32Size(
389
this->producer());
390
}
391
392
// int32 min_consumer = 2;
393
if (this->min_consumer() != 0) {
394
total_size += 1 +
395
::google::protobuf::internal::WireFormatLite::Int32Size(
396
this->min_consumer());
397
}
398
399
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
400
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
401
_cached_size_ = cached_size;
402
GOOGLE_SAFE_CONCURRENT_WRITES_END();
403
return total_size;
404
}
405
406
void VersionDef::MergeFrom(const ::google::protobuf::Message& from) {
407
// @@protoc_insertion_point(generalized_merge_from_start:opencv_tensorflow.VersionDef)
408
GOOGLE_DCHECK_NE(&from, this);
409
const VersionDef* source =
410
::google::protobuf::internal::DynamicCastToGenerated<const VersionDef>(
411
&from);
412
if (source == NULL) {
413
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_tensorflow.VersionDef)
414
::google::protobuf::internal::ReflectionOps::Merge(from, this);
415
} else {
416
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_tensorflow.VersionDef)
417
MergeFrom(*source);
418
}
419
}
420
421
void VersionDef::MergeFrom(const VersionDef& from) {
422
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_tensorflow.VersionDef)
423
GOOGLE_DCHECK_NE(&from, this);
424
_internal_metadata_.MergeFrom(from._internal_metadata_);
425
::google::protobuf::uint32 cached_has_bits = 0;
426
(void) cached_has_bits;
427
428
bad_consumers_.MergeFrom(from.bad_consumers_);
429
if (from.producer() != 0) {
430
set_producer(from.producer());
431
}
432
if (from.min_consumer() != 0) {
433
set_min_consumer(from.min_consumer());
434
}
435
}
436
437
void VersionDef::CopyFrom(const ::google::protobuf::Message& from) {
438
// @@protoc_insertion_point(generalized_copy_from_start:opencv_tensorflow.VersionDef)
439
if (&from == this) return;
440
Clear();
441
MergeFrom(from);
442
}
443
444
void VersionDef::CopyFrom(const VersionDef& from) {
445
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_tensorflow.VersionDef)
446
if (&from == this) return;
447
Clear();
448
MergeFrom(from);
449
}
450
451
bool VersionDef::IsInitialized() const {
452
return true;
453
}
454
455
void VersionDef::Swap(VersionDef* other) {
456
if (other == this) return;
457
if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) {
458
InternalSwap(other);
459
} else {
460
VersionDef* temp = New(GetArenaNoVirtual());
461
temp->MergeFrom(*other);
462
other->CopyFrom(*this);
463
InternalSwap(temp);
464
if (GetArenaNoVirtual() == NULL) {
465
delete temp;
466
}
467
}
468
}
469
void VersionDef::UnsafeArenaSwap(VersionDef* other) {
470
if (other == this) return;
471
GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual());
472
InternalSwap(other);
473
}
474
void VersionDef::InternalSwap(VersionDef* other) {
475
using std::swap;
476
bad_consumers_.InternalSwap(&other->bad_consumers_);
477
swap(producer_, other->producer_);
478
swap(min_consumer_, other->min_consumer_);
479
_internal_metadata_.Swap(&other->_internal_metadata_);
480
swap(_cached_size_, other->_cached_size_);
481
}
482
483
::google::protobuf::Metadata VersionDef::GetMetadata() const {
484
protobuf_versions_2eproto::protobuf_AssignDescriptorsOnce();
485
return ::protobuf_versions_2eproto::file_level_metadata[kIndexInFileMessages];
486
}
487
488
489
// @@protoc_insertion_point(namespace_scope)
490
} // namespace opencv_tensorflow
491
492
// @@protoc_insertion_point(global_scope)
493
494