1 // Generated by the protocol buffer compiler. DO NOT EDIT!
2 // source: fcp/client/http/java/jni.proto
3
4 #include "fcp/client/http/java/jni.pb.h"
5
6 #include <algorithm>
7 #include <cstdint>
8
9 #include <google/protobuf/io/coded_stream.h>
10 #include <google/protobuf/extension_set.h>
11 #include <google/protobuf/wire_format_lite.h>
12 #include <google/protobuf/io/zero_copy_stream_impl_lite.h>
13 // @@protoc_insertion_point(includes)
14 #include <google/protobuf/port_def.inc>
15
16 PROTOBUF_PRAGMA_INIT_SEG
17
18 namespace _pb = ::PROTOBUF_NAMESPACE_ID;
19 namespace _pbi = _pb::internal;
20
21 namespace fcp {
22 namespace client {
23 namespace http {
24 namespace java {
JniHttpRequest(::_pbi::ConstantInitialized)25 PROTOBUF_CONSTEXPR JniHttpRequest::JniHttpRequest(
26 ::_pbi::ConstantInitialized): _impl_{
27 /*decltype(_impl_.extra_headers_)*/{}
28 , /*decltype(_impl_.uri_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
29 , /*decltype(_impl_.method_)*/0
30 , /*decltype(_impl_.has_body_)*/false
31 , /*decltype(_impl_._cached_size_)*/{}} {}
32 struct JniHttpRequestDefaultTypeInternal {
JniHttpRequestDefaultTypeInternalfcp::client::http::java::JniHttpRequestDefaultTypeInternal33 PROTOBUF_CONSTEXPR JniHttpRequestDefaultTypeInternal()
34 : _instance(::_pbi::ConstantInitialized{}) {}
~JniHttpRequestDefaultTypeInternalfcp::client::http::java::JniHttpRequestDefaultTypeInternal35 ~JniHttpRequestDefaultTypeInternal() {}
36 union { // NOLINT(misc-non-private-member-variables-in-classes)
37 JniHttpRequest _instance;
38 };
39 };
40 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 JniHttpRequestDefaultTypeInternal _JniHttpRequest_default_instance_;
JniHttpHeader(::_pbi::ConstantInitialized)41 PROTOBUF_CONSTEXPR JniHttpHeader::JniHttpHeader(
42 ::_pbi::ConstantInitialized): _impl_{
43 /*decltype(_impl_.name_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
44 , /*decltype(_impl_.value_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
45 , /*decltype(_impl_._cached_size_)*/{}} {}
46 struct JniHttpHeaderDefaultTypeInternal {
JniHttpHeaderDefaultTypeInternalfcp::client::http::java::JniHttpHeaderDefaultTypeInternal47 PROTOBUF_CONSTEXPR JniHttpHeaderDefaultTypeInternal()
48 : _instance(::_pbi::ConstantInitialized{}) {}
~JniHttpHeaderDefaultTypeInternalfcp::client::http::java::JniHttpHeaderDefaultTypeInternal49 ~JniHttpHeaderDefaultTypeInternal() {}
50 union { // NOLINT(misc-non-private-member-variables-in-classes)
51 JniHttpHeader _instance;
52 };
53 };
54 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 JniHttpHeaderDefaultTypeInternal _JniHttpHeader_default_instance_;
JniHttpResponse(::_pbi::ConstantInitialized)55 PROTOBUF_CONSTEXPR JniHttpResponse::JniHttpResponse(
56 ::_pbi::ConstantInitialized): _impl_{
57 /*decltype(_impl_.headers_)*/{}
58 , /*decltype(_impl_.code_)*/0
59 , /*decltype(_impl_._cached_size_)*/{}} {}
60 struct JniHttpResponseDefaultTypeInternal {
JniHttpResponseDefaultTypeInternalfcp::client::http::java::JniHttpResponseDefaultTypeInternal61 PROTOBUF_CONSTEXPR JniHttpResponseDefaultTypeInternal()
62 : _instance(::_pbi::ConstantInitialized{}) {}
~JniHttpResponseDefaultTypeInternalfcp::client::http::java::JniHttpResponseDefaultTypeInternal63 ~JniHttpResponseDefaultTypeInternal() {}
64 union { // NOLINT(misc-non-private-member-variables-in-classes)
65 JniHttpResponse _instance;
66 };
67 };
68 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 JniHttpResponseDefaultTypeInternal _JniHttpResponse_default_instance_;
JniHttpSentReceivedBytes(::_pbi::ConstantInitialized)69 PROTOBUF_CONSTEXPR JniHttpSentReceivedBytes::JniHttpSentReceivedBytes(
70 ::_pbi::ConstantInitialized): _impl_{
71 /*decltype(_impl_.sent_bytes_)*/::int64_t{0}
72 , /*decltype(_impl_.received_bytes_)*/::int64_t{0}
73 , /*decltype(_impl_._cached_size_)*/{}} {}
74 struct JniHttpSentReceivedBytesDefaultTypeInternal {
JniHttpSentReceivedBytesDefaultTypeInternalfcp::client::http::java::JniHttpSentReceivedBytesDefaultTypeInternal75 PROTOBUF_CONSTEXPR JniHttpSentReceivedBytesDefaultTypeInternal()
76 : _instance(::_pbi::ConstantInitialized{}) {}
~JniHttpSentReceivedBytesDefaultTypeInternalfcp::client::http::java::JniHttpSentReceivedBytesDefaultTypeInternal77 ~JniHttpSentReceivedBytesDefaultTypeInternal() {}
78 union { // NOLINT(misc-non-private-member-variables-in-classes)
79 JniHttpSentReceivedBytes _instance;
80 };
81 };
82 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 JniHttpSentReceivedBytesDefaultTypeInternal _JniHttpSentReceivedBytes_default_instance_;
83 } // namespace java
84 } // namespace http
85 } // namespace client
86 } // namespace fcp
87 namespace fcp {
88 namespace client {
89 namespace http {
90 namespace java {
JniHttpMethod_IsValid(int value)91 bool JniHttpMethod_IsValid(int value) {
92 switch (value) {
93 case 0:
94 case 1:
95 case 2:
96 case 3:
97 case 4:
98 case 5:
99 case 6:
100 return true;
101 default:
102 return false;
103 }
104 }
105
106 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> JniHttpMethod_strings[7] = {};
107
108 static const char JniHttpMethod_names[] =
109 "HTTP_METHOD_DELETE"
110 "HTTP_METHOD_GET"
111 "HTTP_METHOD_HEAD"
112 "HTTP_METHOD_PATCH"
113 "HTTP_METHOD_POST"
114 "HTTP_METHOD_PUT"
115 "HTTP_METHOD_UNKNOWN";
116
117 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry JniHttpMethod_entries[] = {
118 { {JniHttpMethod_names + 0, 18}, 6 },
119 { {JniHttpMethod_names + 18, 15}, 2 },
120 { {JniHttpMethod_names + 33, 16}, 1 },
121 { {JniHttpMethod_names + 49, 17}, 5 },
122 { {JniHttpMethod_names + 66, 16}, 3 },
123 { {JniHttpMethod_names + 82, 15}, 4 },
124 { {JniHttpMethod_names + 97, 19}, 0 },
125 };
126
127 static const int JniHttpMethod_entries_by_number[] = {
128 6, // 0 -> HTTP_METHOD_UNKNOWN
129 2, // 1 -> HTTP_METHOD_HEAD
130 1, // 2 -> HTTP_METHOD_GET
131 4, // 3 -> HTTP_METHOD_POST
132 5, // 4 -> HTTP_METHOD_PUT
133 3, // 5 -> HTTP_METHOD_PATCH
134 0, // 6 -> HTTP_METHOD_DELETE
135 };
136
JniHttpMethod_Name(JniHttpMethod value)137 const std::string& JniHttpMethod_Name(
138 JniHttpMethod value) {
139 static const bool dummy =
140 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
141 JniHttpMethod_entries,
142 JniHttpMethod_entries_by_number,
143 7, JniHttpMethod_strings);
144 (void) dummy;
145 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
146 JniHttpMethod_entries,
147 JniHttpMethod_entries_by_number,
148 7, value);
149 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
150 JniHttpMethod_strings[idx].get();
151 }
JniHttpMethod_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,JniHttpMethod * value)152 bool JniHttpMethod_Parse(
153 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, JniHttpMethod* value) {
154 int int_value;
155 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
156 JniHttpMethod_entries, 7, name, &int_value);
157 if (success) {
158 *value = static_cast<JniHttpMethod>(int_value);
159 }
160 return success;
161 }
162
163 // ===================================================================
164
165 class JniHttpRequest::_Internal {
166 public:
167 };
168
JniHttpRequest(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)169 JniHttpRequest::JniHttpRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena,
170 bool is_message_owned)
171 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
172 SharedCtor(arena, is_message_owned);
173 // @@protoc_insertion_point(arena_constructor:fcp.client.http.java.JniHttpRequest)
174 }
JniHttpRequest(const JniHttpRequest & from)175 JniHttpRequest::JniHttpRequest(const JniHttpRequest& from)
176 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
177 JniHttpRequest* const _this = this; (void)_this;
178 new (&_impl_) Impl_{
179 decltype(_impl_.extra_headers_){from._impl_.extra_headers_}
180 , decltype(_impl_.uri_){}
181 , decltype(_impl_.method_){}
182 , decltype(_impl_.has_body_){}
183 , /*decltype(_impl_._cached_size_)*/{}};
184
185 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
186 _impl_.uri_.InitDefault();
187 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
188 _impl_.uri_.Set("", GetArenaForAllocation());
189 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
190 if (!from._internal_uri().empty()) {
191 _this->_impl_.uri_.Set(from._internal_uri(),
192 _this->GetArenaForAllocation());
193 }
194 ::memcpy(&_impl_.method_, &from._impl_.method_,
195 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.has_body_) -
196 reinterpret_cast<char*>(&_impl_.method_)) + sizeof(_impl_.has_body_));
197 // @@protoc_insertion_point(copy_constructor:fcp.client.http.java.JniHttpRequest)
198 }
199
SharedCtor(::_pb::Arena * arena,bool is_message_owned)200 inline void JniHttpRequest::SharedCtor(
201 ::_pb::Arena* arena, bool is_message_owned) {
202 (void)arena;
203 (void)is_message_owned;
204 new (&_impl_) Impl_{
205 decltype(_impl_.extra_headers_){arena}
206 , decltype(_impl_.uri_){}
207 , decltype(_impl_.method_){0}
208 , decltype(_impl_.has_body_){false}
209 , /*decltype(_impl_._cached_size_)*/{}
210 };
211 _impl_.uri_.InitDefault();
212 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
213 _impl_.uri_.Set("", GetArenaForAllocation());
214 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
215 }
216
~JniHttpRequest()217 JniHttpRequest::~JniHttpRequest() {
218 // @@protoc_insertion_point(destructor:fcp.client.http.java.JniHttpRequest)
219 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
220 (void)arena;
221 return;
222 }
223 SharedDtor();
224 }
225
SharedDtor()226 inline void JniHttpRequest::SharedDtor() {
227 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
228 _impl_.extra_headers_.~RepeatedPtrField();
229 _impl_.uri_.Destroy();
230 }
231
SetCachedSize(int size) const232 void JniHttpRequest::SetCachedSize(int size) const {
233 _impl_._cached_size_.Set(size);
234 }
235
Clear()236 void JniHttpRequest::Clear() {
237 // @@protoc_insertion_point(message_clear_start:fcp.client.http.java.JniHttpRequest)
238 ::uint32_t cached_has_bits = 0;
239 // Prevent compiler warnings about cached_has_bits being unused
240 (void) cached_has_bits;
241
242 _impl_.extra_headers_.Clear();
243 _impl_.uri_.ClearToEmpty();
244 ::memset(&_impl_.method_, 0, static_cast<size_t>(
245 reinterpret_cast<char*>(&_impl_.has_body_) -
246 reinterpret_cast<char*>(&_impl_.method_)) + sizeof(_impl_.has_body_));
247 _internal_metadata_.Clear<std::string>();
248 }
249
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)250 const char* JniHttpRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
251 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
252 while (!ctx->Done(&ptr)) {
253 ::uint32_t tag;
254 ptr = ::_pbi::ReadTag(ptr, &tag);
255 switch (tag >> 3) {
256 // string uri = 1;
257 case 1:
258 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
259 auto str = _internal_mutable_uri();
260 ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
261 CHK_(ptr);
262 CHK_(::_pbi::VerifyUTF8(str, nullptr));
263 } else {
264 goto handle_unusual;
265 }
266 continue;
267 // .fcp.client.http.java.JniHttpMethod method = 2;
268 case 2:
269 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
270 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
271 CHK_(ptr);
272 _internal_set_method(static_cast<::fcp::client::http::java::JniHttpMethod>(val));
273 } else {
274 goto handle_unusual;
275 }
276 continue;
277 // repeated .fcp.client.http.java.JniHttpHeader extra_headers = 3;
278 case 3:
279 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 26)) {
280 ptr -= 1;
281 do {
282 ptr += 1;
283 ptr = ctx->ParseMessage(_internal_add_extra_headers(), ptr);
284 CHK_(ptr);
285 if (!ctx->DataAvailable(ptr)) break;
286 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<26>(ptr));
287 } else {
288 goto handle_unusual;
289 }
290 continue;
291 // bool has_body = 4;
292 case 4:
293 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
294 _impl_.has_body_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
295 CHK_(ptr);
296 } else {
297 goto handle_unusual;
298 }
299 continue;
300 default:
301 goto handle_unusual;
302 } // switch
303 handle_unusual:
304 if ((tag == 0) || ((tag & 7) == 4)) {
305 CHK_(ptr);
306 ctx->SetLastTag(tag);
307 goto message_done;
308 }
309 ptr = UnknownFieldParse(
310 tag,
311 _internal_metadata_.mutable_unknown_fields<std::string>(),
312 ptr, ctx);
313 CHK_(ptr != nullptr);
314 } // while
315 message_done:
316 return ptr;
317 failure:
318 ptr = nullptr;
319 goto message_done;
320 #undef CHK_
321 }
322
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const323 ::uint8_t* JniHttpRequest::_InternalSerialize(
324 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
325 // @@protoc_insertion_point(serialize_to_array_start:fcp.client.http.java.JniHttpRequest)
326 ::uint32_t cached_has_bits = 0;
327 (void) cached_has_bits;
328
329 // string uri = 1;
330 if (!this->_internal_uri().empty()) {
331 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
332 this->_internal_uri().data(), static_cast<int>(this->_internal_uri().length()),
333 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
334 "fcp.client.http.java.JniHttpRequest.uri");
335 target = stream->WriteStringMaybeAliased(
336 1, this->_internal_uri(), target);
337 }
338
339 // .fcp.client.http.java.JniHttpMethod method = 2;
340 if (this->_internal_method() != 0) {
341 target = stream->EnsureSpace(target);
342 target = ::_pbi::WireFormatLite::WriteEnumToArray(
343 2, this->_internal_method(), target);
344 }
345
346 // repeated .fcp.client.http.java.JniHttpHeader extra_headers = 3;
347 for (unsigned i = 0,
348 n = static_cast<unsigned>(this->_internal_extra_headers_size()); i < n; i++) {
349 const auto& repfield = this->_internal_extra_headers(i);
350 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
351 InternalWriteMessage(3, repfield, repfield.GetCachedSize(), target, stream);
352 }
353
354 // bool has_body = 4;
355 if (this->_internal_has_body() != 0) {
356 target = stream->EnsureSpace(target);
357 target = ::_pbi::WireFormatLite::WriteBoolToArray(4, this->_internal_has_body(), target);
358 }
359
360 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
361 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
362 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
363 }
364 // @@protoc_insertion_point(serialize_to_array_end:fcp.client.http.java.JniHttpRequest)
365 return target;
366 }
367
ByteSizeLong() const368 size_t JniHttpRequest::ByteSizeLong() const {
369 // @@protoc_insertion_point(message_byte_size_start:fcp.client.http.java.JniHttpRequest)
370 size_t total_size = 0;
371
372 ::uint32_t cached_has_bits = 0;
373 // Prevent compiler warnings about cached_has_bits being unused
374 (void) cached_has_bits;
375
376 // repeated .fcp.client.http.java.JniHttpHeader extra_headers = 3;
377 total_size += 1UL * this->_internal_extra_headers_size();
378 for (const auto& msg : this->_impl_.extra_headers_) {
379 total_size +=
380 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
381 }
382
383 // string uri = 1;
384 if (!this->_internal_uri().empty()) {
385 total_size += 1 +
386 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
387 this->_internal_uri());
388 }
389
390 // .fcp.client.http.java.JniHttpMethod method = 2;
391 if (this->_internal_method() != 0) {
392 total_size += 1 +
393 ::_pbi::WireFormatLite::EnumSize(this->_internal_method());
394 }
395
396 // bool has_body = 4;
397 if (this->_internal_has_body() != 0) {
398 total_size += 1 + 1;
399 }
400
401 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
402 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
403 }
404 int cached_size = ::_pbi::ToCachedSize(total_size);
405 SetCachedSize(cached_size);
406 return total_size;
407 }
408
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)409 void JniHttpRequest::CheckTypeAndMergeFrom(
410 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
411 MergeFrom(*::_pbi::DownCast<const JniHttpRequest*>(
412 &from));
413 }
414
MergeFrom(const JniHttpRequest & from)415 void JniHttpRequest::MergeFrom(const JniHttpRequest& from) {
416 JniHttpRequest* const _this = this;
417 // @@protoc_insertion_point(class_specific_merge_from_start:fcp.client.http.java.JniHttpRequest)
418 GOOGLE_DCHECK_NE(&from, _this);
419 ::uint32_t cached_has_bits = 0;
420 (void) cached_has_bits;
421
422 _this->_impl_.extra_headers_.MergeFrom(from._impl_.extra_headers_);
423 if (!from._internal_uri().empty()) {
424 _this->_internal_set_uri(from._internal_uri());
425 }
426 if (from._internal_method() != 0) {
427 _this->_internal_set_method(from._internal_method());
428 }
429 if (from._internal_has_body() != 0) {
430 _this->_internal_set_has_body(from._internal_has_body());
431 }
432 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
433 }
434
CopyFrom(const JniHttpRequest & from)435 void JniHttpRequest::CopyFrom(const JniHttpRequest& from) {
436 // @@protoc_insertion_point(class_specific_copy_from_start:fcp.client.http.java.JniHttpRequest)
437 if (&from == this) return;
438 Clear();
439 MergeFrom(from);
440 }
441
IsInitialized() const442 bool JniHttpRequest::IsInitialized() const {
443 return true;
444 }
445
InternalSwap(JniHttpRequest * other)446 void JniHttpRequest::InternalSwap(JniHttpRequest* other) {
447 using std::swap;
448 auto* lhs_arena = GetArenaForAllocation();
449 auto* rhs_arena = other->GetArenaForAllocation();
450 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
451 _impl_.extra_headers_.InternalSwap(&other->_impl_.extra_headers_);
452 ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
453 &_impl_.uri_, lhs_arena,
454 &other->_impl_.uri_, rhs_arena
455 );
456 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
457 PROTOBUF_FIELD_OFFSET(JniHttpRequest, _impl_.has_body_)
458 + sizeof(JniHttpRequest::_impl_.has_body_) // NOLINT
459 - PROTOBUF_FIELD_OFFSET(JniHttpRequest, _impl_.method_)>(
460 reinterpret_cast<char*>(&_impl_.method_),
461 reinterpret_cast<char*>(&other->_impl_.method_));
462 }
463
GetTypeName() const464 std::string JniHttpRequest::GetTypeName() const {
465 return "fcp.client.http.java.JniHttpRequest";
466 }
467
468
469 // ===================================================================
470
471 class JniHttpHeader::_Internal {
472 public:
473 };
474
JniHttpHeader(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)475 JniHttpHeader::JniHttpHeader(::PROTOBUF_NAMESPACE_ID::Arena* arena,
476 bool is_message_owned)
477 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
478 SharedCtor(arena, is_message_owned);
479 // @@protoc_insertion_point(arena_constructor:fcp.client.http.java.JniHttpHeader)
480 }
JniHttpHeader(const JniHttpHeader & from)481 JniHttpHeader::JniHttpHeader(const JniHttpHeader& from)
482 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
483 JniHttpHeader* const _this = this; (void)_this;
484 new (&_impl_) Impl_{
485 decltype(_impl_.name_){}
486 , decltype(_impl_.value_){}
487 , /*decltype(_impl_._cached_size_)*/{}};
488
489 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
490 _impl_.name_.InitDefault();
491 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
492 _impl_.name_.Set("", GetArenaForAllocation());
493 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
494 if (!from._internal_name().empty()) {
495 _this->_impl_.name_.Set(from._internal_name(),
496 _this->GetArenaForAllocation());
497 }
498 _impl_.value_.InitDefault();
499 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
500 _impl_.value_.Set("", GetArenaForAllocation());
501 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
502 if (!from._internal_value().empty()) {
503 _this->_impl_.value_.Set(from._internal_value(),
504 _this->GetArenaForAllocation());
505 }
506 // @@protoc_insertion_point(copy_constructor:fcp.client.http.java.JniHttpHeader)
507 }
508
SharedCtor(::_pb::Arena * arena,bool is_message_owned)509 inline void JniHttpHeader::SharedCtor(
510 ::_pb::Arena* arena, bool is_message_owned) {
511 (void)arena;
512 (void)is_message_owned;
513 new (&_impl_) Impl_{
514 decltype(_impl_.name_){}
515 , decltype(_impl_.value_){}
516 , /*decltype(_impl_._cached_size_)*/{}
517 };
518 _impl_.name_.InitDefault();
519 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
520 _impl_.name_.Set("", GetArenaForAllocation());
521 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
522 _impl_.value_.InitDefault();
523 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
524 _impl_.value_.Set("", GetArenaForAllocation());
525 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
526 }
527
~JniHttpHeader()528 JniHttpHeader::~JniHttpHeader() {
529 // @@protoc_insertion_point(destructor:fcp.client.http.java.JniHttpHeader)
530 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
531 (void)arena;
532 return;
533 }
534 SharedDtor();
535 }
536
SharedDtor()537 inline void JniHttpHeader::SharedDtor() {
538 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
539 _impl_.name_.Destroy();
540 _impl_.value_.Destroy();
541 }
542
SetCachedSize(int size) const543 void JniHttpHeader::SetCachedSize(int size) const {
544 _impl_._cached_size_.Set(size);
545 }
546
Clear()547 void JniHttpHeader::Clear() {
548 // @@protoc_insertion_point(message_clear_start:fcp.client.http.java.JniHttpHeader)
549 ::uint32_t cached_has_bits = 0;
550 // Prevent compiler warnings about cached_has_bits being unused
551 (void) cached_has_bits;
552
553 _impl_.name_.ClearToEmpty();
554 _impl_.value_.ClearToEmpty();
555 _internal_metadata_.Clear<std::string>();
556 }
557
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)558 const char* JniHttpHeader::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
559 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
560 while (!ctx->Done(&ptr)) {
561 ::uint32_t tag;
562 ptr = ::_pbi::ReadTag(ptr, &tag);
563 switch (tag >> 3) {
564 // string name = 1;
565 case 1:
566 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
567 auto str = _internal_mutable_name();
568 ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
569 CHK_(ptr);
570 CHK_(::_pbi::VerifyUTF8(str, nullptr));
571 } else {
572 goto handle_unusual;
573 }
574 continue;
575 // string value = 2;
576 case 2:
577 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
578 auto str = _internal_mutable_value();
579 ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
580 CHK_(ptr);
581 CHK_(::_pbi::VerifyUTF8(str, nullptr));
582 } else {
583 goto handle_unusual;
584 }
585 continue;
586 default:
587 goto handle_unusual;
588 } // switch
589 handle_unusual:
590 if ((tag == 0) || ((tag & 7) == 4)) {
591 CHK_(ptr);
592 ctx->SetLastTag(tag);
593 goto message_done;
594 }
595 ptr = UnknownFieldParse(
596 tag,
597 _internal_metadata_.mutable_unknown_fields<std::string>(),
598 ptr, ctx);
599 CHK_(ptr != nullptr);
600 } // while
601 message_done:
602 return ptr;
603 failure:
604 ptr = nullptr;
605 goto message_done;
606 #undef CHK_
607 }
608
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const609 ::uint8_t* JniHttpHeader::_InternalSerialize(
610 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
611 // @@protoc_insertion_point(serialize_to_array_start:fcp.client.http.java.JniHttpHeader)
612 ::uint32_t cached_has_bits = 0;
613 (void) cached_has_bits;
614
615 // string name = 1;
616 if (!this->_internal_name().empty()) {
617 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
618 this->_internal_name().data(), static_cast<int>(this->_internal_name().length()),
619 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
620 "fcp.client.http.java.JniHttpHeader.name");
621 target = stream->WriteStringMaybeAliased(
622 1, this->_internal_name(), target);
623 }
624
625 // string value = 2;
626 if (!this->_internal_value().empty()) {
627 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
628 this->_internal_value().data(), static_cast<int>(this->_internal_value().length()),
629 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
630 "fcp.client.http.java.JniHttpHeader.value");
631 target = stream->WriteStringMaybeAliased(
632 2, this->_internal_value(), target);
633 }
634
635 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
636 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
637 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
638 }
639 // @@protoc_insertion_point(serialize_to_array_end:fcp.client.http.java.JniHttpHeader)
640 return target;
641 }
642
ByteSizeLong() const643 size_t JniHttpHeader::ByteSizeLong() const {
644 // @@protoc_insertion_point(message_byte_size_start:fcp.client.http.java.JniHttpHeader)
645 size_t total_size = 0;
646
647 ::uint32_t cached_has_bits = 0;
648 // Prevent compiler warnings about cached_has_bits being unused
649 (void) cached_has_bits;
650
651 // string name = 1;
652 if (!this->_internal_name().empty()) {
653 total_size += 1 +
654 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
655 this->_internal_name());
656 }
657
658 // string value = 2;
659 if (!this->_internal_value().empty()) {
660 total_size += 1 +
661 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
662 this->_internal_value());
663 }
664
665 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
666 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
667 }
668 int cached_size = ::_pbi::ToCachedSize(total_size);
669 SetCachedSize(cached_size);
670 return total_size;
671 }
672
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)673 void JniHttpHeader::CheckTypeAndMergeFrom(
674 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
675 MergeFrom(*::_pbi::DownCast<const JniHttpHeader*>(
676 &from));
677 }
678
MergeFrom(const JniHttpHeader & from)679 void JniHttpHeader::MergeFrom(const JniHttpHeader& from) {
680 JniHttpHeader* const _this = this;
681 // @@protoc_insertion_point(class_specific_merge_from_start:fcp.client.http.java.JniHttpHeader)
682 GOOGLE_DCHECK_NE(&from, _this);
683 ::uint32_t cached_has_bits = 0;
684 (void) cached_has_bits;
685
686 if (!from._internal_name().empty()) {
687 _this->_internal_set_name(from._internal_name());
688 }
689 if (!from._internal_value().empty()) {
690 _this->_internal_set_value(from._internal_value());
691 }
692 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
693 }
694
CopyFrom(const JniHttpHeader & from)695 void JniHttpHeader::CopyFrom(const JniHttpHeader& from) {
696 // @@protoc_insertion_point(class_specific_copy_from_start:fcp.client.http.java.JniHttpHeader)
697 if (&from == this) return;
698 Clear();
699 MergeFrom(from);
700 }
701
IsInitialized() const702 bool JniHttpHeader::IsInitialized() const {
703 return true;
704 }
705
InternalSwap(JniHttpHeader * other)706 void JniHttpHeader::InternalSwap(JniHttpHeader* other) {
707 using std::swap;
708 auto* lhs_arena = GetArenaForAllocation();
709 auto* rhs_arena = other->GetArenaForAllocation();
710 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
711 ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
712 &_impl_.name_, lhs_arena,
713 &other->_impl_.name_, rhs_arena
714 );
715 ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
716 &_impl_.value_, lhs_arena,
717 &other->_impl_.value_, rhs_arena
718 );
719 }
720
GetTypeName() const721 std::string JniHttpHeader::GetTypeName() const {
722 return "fcp.client.http.java.JniHttpHeader";
723 }
724
725
726 // ===================================================================
727
728 class JniHttpResponse::_Internal {
729 public:
730 };
731
JniHttpResponse(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)732 JniHttpResponse::JniHttpResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena,
733 bool is_message_owned)
734 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
735 SharedCtor(arena, is_message_owned);
736 // @@protoc_insertion_point(arena_constructor:fcp.client.http.java.JniHttpResponse)
737 }
JniHttpResponse(const JniHttpResponse & from)738 JniHttpResponse::JniHttpResponse(const JniHttpResponse& from)
739 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
740 JniHttpResponse* const _this = this; (void)_this;
741 new (&_impl_) Impl_{
742 decltype(_impl_.headers_){from._impl_.headers_}
743 , decltype(_impl_.code_){}
744 , /*decltype(_impl_._cached_size_)*/{}};
745
746 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
747 _this->_impl_.code_ = from._impl_.code_;
748 // @@protoc_insertion_point(copy_constructor:fcp.client.http.java.JniHttpResponse)
749 }
750
SharedCtor(::_pb::Arena * arena,bool is_message_owned)751 inline void JniHttpResponse::SharedCtor(
752 ::_pb::Arena* arena, bool is_message_owned) {
753 (void)arena;
754 (void)is_message_owned;
755 new (&_impl_) Impl_{
756 decltype(_impl_.headers_){arena}
757 , decltype(_impl_.code_){0}
758 , /*decltype(_impl_._cached_size_)*/{}
759 };
760 }
761
~JniHttpResponse()762 JniHttpResponse::~JniHttpResponse() {
763 // @@protoc_insertion_point(destructor:fcp.client.http.java.JniHttpResponse)
764 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
765 (void)arena;
766 return;
767 }
768 SharedDtor();
769 }
770
SharedDtor()771 inline void JniHttpResponse::SharedDtor() {
772 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
773 _impl_.headers_.~RepeatedPtrField();
774 }
775
SetCachedSize(int size) const776 void JniHttpResponse::SetCachedSize(int size) const {
777 _impl_._cached_size_.Set(size);
778 }
779
Clear()780 void JniHttpResponse::Clear() {
781 // @@protoc_insertion_point(message_clear_start:fcp.client.http.java.JniHttpResponse)
782 ::uint32_t cached_has_bits = 0;
783 // Prevent compiler warnings about cached_has_bits being unused
784 (void) cached_has_bits;
785
786 _impl_.headers_.Clear();
787 _impl_.code_ = 0;
788 _internal_metadata_.Clear<std::string>();
789 }
790
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)791 const char* JniHttpResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
792 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
793 while (!ctx->Done(&ptr)) {
794 ::uint32_t tag;
795 ptr = ::_pbi::ReadTag(ptr, &tag);
796 switch (tag >> 3) {
797 // int32 code = 1;
798 case 1:
799 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
800 _impl_.code_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
801 CHK_(ptr);
802 } else {
803 goto handle_unusual;
804 }
805 continue;
806 // repeated .fcp.client.http.java.JniHttpHeader headers = 2;
807 case 2:
808 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
809 ptr -= 1;
810 do {
811 ptr += 1;
812 ptr = ctx->ParseMessage(_internal_add_headers(), ptr);
813 CHK_(ptr);
814 if (!ctx->DataAvailable(ptr)) break;
815 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<18>(ptr));
816 } else {
817 goto handle_unusual;
818 }
819 continue;
820 default:
821 goto handle_unusual;
822 } // switch
823 handle_unusual:
824 if ((tag == 0) || ((tag & 7) == 4)) {
825 CHK_(ptr);
826 ctx->SetLastTag(tag);
827 goto message_done;
828 }
829 ptr = UnknownFieldParse(
830 tag,
831 _internal_metadata_.mutable_unknown_fields<std::string>(),
832 ptr, ctx);
833 CHK_(ptr != nullptr);
834 } // while
835 message_done:
836 return ptr;
837 failure:
838 ptr = nullptr;
839 goto message_done;
840 #undef CHK_
841 }
842
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const843 ::uint8_t* JniHttpResponse::_InternalSerialize(
844 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
845 // @@protoc_insertion_point(serialize_to_array_start:fcp.client.http.java.JniHttpResponse)
846 ::uint32_t cached_has_bits = 0;
847 (void) cached_has_bits;
848
849 // int32 code = 1;
850 if (this->_internal_code() != 0) {
851 target = stream->EnsureSpace(target);
852 target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_code(), target);
853 }
854
855 // repeated .fcp.client.http.java.JniHttpHeader headers = 2;
856 for (unsigned i = 0,
857 n = static_cast<unsigned>(this->_internal_headers_size()); i < n; i++) {
858 const auto& repfield = this->_internal_headers(i);
859 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
860 InternalWriteMessage(2, repfield, repfield.GetCachedSize(), target, stream);
861 }
862
863 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
864 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
865 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
866 }
867 // @@protoc_insertion_point(serialize_to_array_end:fcp.client.http.java.JniHttpResponse)
868 return target;
869 }
870
ByteSizeLong() const871 size_t JniHttpResponse::ByteSizeLong() const {
872 // @@protoc_insertion_point(message_byte_size_start:fcp.client.http.java.JniHttpResponse)
873 size_t total_size = 0;
874
875 ::uint32_t cached_has_bits = 0;
876 // Prevent compiler warnings about cached_has_bits being unused
877 (void) cached_has_bits;
878
879 // repeated .fcp.client.http.java.JniHttpHeader headers = 2;
880 total_size += 1UL * this->_internal_headers_size();
881 for (const auto& msg : this->_impl_.headers_) {
882 total_size +=
883 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
884 }
885
886 // int32 code = 1;
887 if (this->_internal_code() != 0) {
888 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_code());
889 }
890
891 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
892 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
893 }
894 int cached_size = ::_pbi::ToCachedSize(total_size);
895 SetCachedSize(cached_size);
896 return total_size;
897 }
898
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)899 void JniHttpResponse::CheckTypeAndMergeFrom(
900 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
901 MergeFrom(*::_pbi::DownCast<const JniHttpResponse*>(
902 &from));
903 }
904
MergeFrom(const JniHttpResponse & from)905 void JniHttpResponse::MergeFrom(const JniHttpResponse& from) {
906 JniHttpResponse* const _this = this;
907 // @@protoc_insertion_point(class_specific_merge_from_start:fcp.client.http.java.JniHttpResponse)
908 GOOGLE_DCHECK_NE(&from, _this);
909 ::uint32_t cached_has_bits = 0;
910 (void) cached_has_bits;
911
912 _this->_impl_.headers_.MergeFrom(from._impl_.headers_);
913 if (from._internal_code() != 0) {
914 _this->_internal_set_code(from._internal_code());
915 }
916 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
917 }
918
CopyFrom(const JniHttpResponse & from)919 void JniHttpResponse::CopyFrom(const JniHttpResponse& from) {
920 // @@protoc_insertion_point(class_specific_copy_from_start:fcp.client.http.java.JniHttpResponse)
921 if (&from == this) return;
922 Clear();
923 MergeFrom(from);
924 }
925
IsInitialized() const926 bool JniHttpResponse::IsInitialized() const {
927 return true;
928 }
929
InternalSwap(JniHttpResponse * other)930 void JniHttpResponse::InternalSwap(JniHttpResponse* other) {
931 using std::swap;
932 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
933 _impl_.headers_.InternalSwap(&other->_impl_.headers_);
934 swap(_impl_.code_, other->_impl_.code_);
935 }
936
GetTypeName() const937 std::string JniHttpResponse::GetTypeName() const {
938 return "fcp.client.http.java.JniHttpResponse";
939 }
940
941
942 // ===================================================================
943
944 class JniHttpSentReceivedBytes::_Internal {
945 public:
946 };
947
JniHttpSentReceivedBytes(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)948 JniHttpSentReceivedBytes::JniHttpSentReceivedBytes(::PROTOBUF_NAMESPACE_ID::Arena* arena,
949 bool is_message_owned)
950 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
951 SharedCtor(arena, is_message_owned);
952 // @@protoc_insertion_point(arena_constructor:fcp.client.http.java.JniHttpSentReceivedBytes)
953 }
JniHttpSentReceivedBytes(const JniHttpSentReceivedBytes & from)954 JniHttpSentReceivedBytes::JniHttpSentReceivedBytes(const JniHttpSentReceivedBytes& from)
955 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
956 JniHttpSentReceivedBytes* const _this = this; (void)_this;
957 new (&_impl_) Impl_{
958 decltype(_impl_.sent_bytes_){}
959 , decltype(_impl_.received_bytes_){}
960 , /*decltype(_impl_._cached_size_)*/{}};
961
962 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
963 ::memcpy(&_impl_.sent_bytes_, &from._impl_.sent_bytes_,
964 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.received_bytes_) -
965 reinterpret_cast<char*>(&_impl_.sent_bytes_)) + sizeof(_impl_.received_bytes_));
966 // @@protoc_insertion_point(copy_constructor:fcp.client.http.java.JniHttpSentReceivedBytes)
967 }
968
SharedCtor(::_pb::Arena * arena,bool is_message_owned)969 inline void JniHttpSentReceivedBytes::SharedCtor(
970 ::_pb::Arena* arena, bool is_message_owned) {
971 (void)arena;
972 (void)is_message_owned;
973 new (&_impl_) Impl_{
974 decltype(_impl_.sent_bytes_){::int64_t{0}}
975 , decltype(_impl_.received_bytes_){::int64_t{0}}
976 , /*decltype(_impl_._cached_size_)*/{}
977 };
978 }
979
~JniHttpSentReceivedBytes()980 JniHttpSentReceivedBytes::~JniHttpSentReceivedBytes() {
981 // @@protoc_insertion_point(destructor:fcp.client.http.java.JniHttpSentReceivedBytes)
982 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
983 (void)arena;
984 return;
985 }
986 SharedDtor();
987 }
988
SharedDtor()989 inline void JniHttpSentReceivedBytes::SharedDtor() {
990 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
991 }
992
SetCachedSize(int size) const993 void JniHttpSentReceivedBytes::SetCachedSize(int size) const {
994 _impl_._cached_size_.Set(size);
995 }
996
Clear()997 void JniHttpSentReceivedBytes::Clear() {
998 // @@protoc_insertion_point(message_clear_start:fcp.client.http.java.JniHttpSentReceivedBytes)
999 ::uint32_t cached_has_bits = 0;
1000 // Prevent compiler warnings about cached_has_bits being unused
1001 (void) cached_has_bits;
1002
1003 ::memset(&_impl_.sent_bytes_, 0, static_cast<size_t>(
1004 reinterpret_cast<char*>(&_impl_.received_bytes_) -
1005 reinterpret_cast<char*>(&_impl_.sent_bytes_)) + sizeof(_impl_.received_bytes_));
1006 _internal_metadata_.Clear<std::string>();
1007 }
1008
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1009 const char* JniHttpSentReceivedBytes::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1010 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1011 while (!ctx->Done(&ptr)) {
1012 ::uint32_t tag;
1013 ptr = ::_pbi::ReadTag(ptr, &tag);
1014 switch (tag >> 3) {
1015 // int64 sent_bytes = 1;
1016 case 1:
1017 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
1018 _impl_.sent_bytes_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1019 CHK_(ptr);
1020 } else {
1021 goto handle_unusual;
1022 }
1023 continue;
1024 // int64 received_bytes = 2;
1025 case 2:
1026 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
1027 _impl_.received_bytes_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1028 CHK_(ptr);
1029 } else {
1030 goto handle_unusual;
1031 }
1032 continue;
1033 default:
1034 goto handle_unusual;
1035 } // switch
1036 handle_unusual:
1037 if ((tag == 0) || ((tag & 7) == 4)) {
1038 CHK_(ptr);
1039 ctx->SetLastTag(tag);
1040 goto message_done;
1041 }
1042 ptr = UnknownFieldParse(
1043 tag,
1044 _internal_metadata_.mutable_unknown_fields<std::string>(),
1045 ptr, ctx);
1046 CHK_(ptr != nullptr);
1047 } // while
1048 message_done:
1049 return ptr;
1050 failure:
1051 ptr = nullptr;
1052 goto message_done;
1053 #undef CHK_
1054 }
1055
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1056 ::uint8_t* JniHttpSentReceivedBytes::_InternalSerialize(
1057 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1058 // @@protoc_insertion_point(serialize_to_array_start:fcp.client.http.java.JniHttpSentReceivedBytes)
1059 ::uint32_t cached_has_bits = 0;
1060 (void) cached_has_bits;
1061
1062 // int64 sent_bytes = 1;
1063 if (this->_internal_sent_bytes() != 0) {
1064 target = stream->EnsureSpace(target);
1065 target = ::_pbi::WireFormatLite::WriteInt64ToArray(1, this->_internal_sent_bytes(), target);
1066 }
1067
1068 // int64 received_bytes = 2;
1069 if (this->_internal_received_bytes() != 0) {
1070 target = stream->EnsureSpace(target);
1071 target = ::_pbi::WireFormatLite::WriteInt64ToArray(2, this->_internal_received_bytes(), target);
1072 }
1073
1074 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1075 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
1076 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
1077 }
1078 // @@protoc_insertion_point(serialize_to_array_end:fcp.client.http.java.JniHttpSentReceivedBytes)
1079 return target;
1080 }
1081
ByteSizeLong() const1082 size_t JniHttpSentReceivedBytes::ByteSizeLong() const {
1083 // @@protoc_insertion_point(message_byte_size_start:fcp.client.http.java.JniHttpSentReceivedBytes)
1084 size_t total_size = 0;
1085
1086 ::uint32_t cached_has_bits = 0;
1087 // Prevent compiler warnings about cached_has_bits being unused
1088 (void) cached_has_bits;
1089
1090 // int64 sent_bytes = 1;
1091 if (this->_internal_sent_bytes() != 0) {
1092 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_sent_bytes());
1093 }
1094
1095 // int64 received_bytes = 2;
1096 if (this->_internal_received_bytes() != 0) {
1097 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_received_bytes());
1098 }
1099
1100 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1101 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
1102 }
1103 int cached_size = ::_pbi::ToCachedSize(total_size);
1104 SetCachedSize(cached_size);
1105 return total_size;
1106 }
1107
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)1108 void JniHttpSentReceivedBytes::CheckTypeAndMergeFrom(
1109 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
1110 MergeFrom(*::_pbi::DownCast<const JniHttpSentReceivedBytes*>(
1111 &from));
1112 }
1113
MergeFrom(const JniHttpSentReceivedBytes & from)1114 void JniHttpSentReceivedBytes::MergeFrom(const JniHttpSentReceivedBytes& from) {
1115 JniHttpSentReceivedBytes* const _this = this;
1116 // @@protoc_insertion_point(class_specific_merge_from_start:fcp.client.http.java.JniHttpSentReceivedBytes)
1117 GOOGLE_DCHECK_NE(&from, _this);
1118 ::uint32_t cached_has_bits = 0;
1119 (void) cached_has_bits;
1120
1121 if (from._internal_sent_bytes() != 0) {
1122 _this->_internal_set_sent_bytes(from._internal_sent_bytes());
1123 }
1124 if (from._internal_received_bytes() != 0) {
1125 _this->_internal_set_received_bytes(from._internal_received_bytes());
1126 }
1127 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1128 }
1129
CopyFrom(const JniHttpSentReceivedBytes & from)1130 void JniHttpSentReceivedBytes::CopyFrom(const JniHttpSentReceivedBytes& from) {
1131 // @@protoc_insertion_point(class_specific_copy_from_start:fcp.client.http.java.JniHttpSentReceivedBytes)
1132 if (&from == this) return;
1133 Clear();
1134 MergeFrom(from);
1135 }
1136
IsInitialized() const1137 bool JniHttpSentReceivedBytes::IsInitialized() const {
1138 return true;
1139 }
1140
InternalSwap(JniHttpSentReceivedBytes * other)1141 void JniHttpSentReceivedBytes::InternalSwap(JniHttpSentReceivedBytes* other) {
1142 using std::swap;
1143 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
1144 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
1145 PROTOBUF_FIELD_OFFSET(JniHttpSentReceivedBytes, _impl_.received_bytes_)
1146 + sizeof(JniHttpSentReceivedBytes::_impl_.received_bytes_) // NOLINT
1147 - PROTOBUF_FIELD_OFFSET(JniHttpSentReceivedBytes, _impl_.sent_bytes_)>(
1148 reinterpret_cast<char*>(&_impl_.sent_bytes_),
1149 reinterpret_cast<char*>(&other->_impl_.sent_bytes_));
1150 }
1151
GetTypeName() const1152 std::string JniHttpSentReceivedBytes::GetTypeName() const {
1153 return "fcp.client.http.java.JniHttpSentReceivedBytes";
1154 }
1155
1156
1157 // @@protoc_insertion_point(namespace_scope)
1158 } // namespace java
1159 } // namespace http
1160 } // namespace client
1161 } // namespace fcp
1162 PROTOBUF_NAMESPACE_OPEN
1163 template<> PROTOBUF_NOINLINE ::fcp::client::http::java::JniHttpRequest*
CreateMaybeMessage(Arena * arena)1164 Arena::CreateMaybeMessage< ::fcp::client::http::java::JniHttpRequest >(Arena* arena) {
1165 return Arena::CreateMessageInternal< ::fcp::client::http::java::JniHttpRequest >(arena);
1166 }
1167 template<> PROTOBUF_NOINLINE ::fcp::client::http::java::JniHttpHeader*
CreateMaybeMessage(Arena * arena)1168 Arena::CreateMaybeMessage< ::fcp::client::http::java::JniHttpHeader >(Arena* arena) {
1169 return Arena::CreateMessageInternal< ::fcp::client::http::java::JniHttpHeader >(arena);
1170 }
1171 template<> PROTOBUF_NOINLINE ::fcp::client::http::java::JniHttpResponse*
CreateMaybeMessage(Arena * arena)1172 Arena::CreateMaybeMessage< ::fcp::client::http::java::JniHttpResponse >(Arena* arena) {
1173 return Arena::CreateMessageInternal< ::fcp::client::http::java::JniHttpResponse >(arena);
1174 }
1175 template<> PROTOBUF_NOINLINE ::fcp::client::http::java::JniHttpSentReceivedBytes*
CreateMaybeMessage(Arena * arena)1176 Arena::CreateMaybeMessage< ::fcp::client::http::java::JniHttpSentReceivedBytes >(Arena* arena) {
1177 return Arena::CreateMessageInternal< ::fcp::client::http::java::JniHttpSentReceivedBytes >(arena);
1178 }
1179 PROTOBUF_NAMESPACE_CLOSE
1180
1181 // @@protoc_insertion_point(global_scope)
1182 #include <google/protobuf/port_undef.inc>
1183