/src/brpc/build/brpc/options.pb.cc
Line | Count | Source |
1 | | // Generated by the protocol buffer compiler. DO NOT EDIT! |
2 | | // source: brpc/options.proto |
3 | | |
4 | | #include "brpc/options.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/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> |
16 | | // This is a temporary google only hack |
17 | | #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
18 | | #include "third_party/protobuf/version.h" |
19 | | #endif |
20 | | // @@protoc_insertion_point(includes) |
21 | | |
22 | | namespace brpc { |
23 | | class ChunkInfoDefaultTypeInternal { |
24 | | public: |
25 | | ::google::protobuf::internal::ExplicitlyConstructed<ChunkInfo> |
26 | | _instance; |
27 | | } _ChunkInfo_default_instance_; |
28 | | } // namespace brpc |
29 | | namespace protobuf_brpc_2foptions_2eproto { |
30 | 2 | static void InitDefaultsChunkInfo() { |
31 | 2 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
32 | | |
33 | 2 | { |
34 | 2 | void* ptr = &::brpc::_ChunkInfo_default_instance_; |
35 | 2 | new (ptr) ::brpc::ChunkInfo(); |
36 | 2 | ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); |
37 | 2 | } |
38 | 2 | ::brpc::ChunkInfo::InitAsDefaultInstance(); |
39 | 2 | } |
40 | | |
41 | | ::google::protobuf::internal::SCCInfo<0> scc_info_ChunkInfo = |
42 | | {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsChunkInfo}, {}}; |
43 | | |
44 | 2 | void InitDefaults() { |
45 | 2 | ::google::protobuf::internal::InitSCC(&scc_info_ChunkInfo.base); |
46 | 2 | } |
47 | | |
48 | | ::google::protobuf::Metadata file_level_metadata[1]; |
49 | | const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[6]; |
50 | | |
51 | | const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
52 | | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::brpc::ChunkInfo, _has_bits_), |
53 | | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::brpc::ChunkInfo, _internal_metadata_), |
54 | | ~0u, // no _extensions_ |
55 | | ~0u, // no _oneof_case_ |
56 | | ~0u, // no _weak_field_map_ |
57 | | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::brpc::ChunkInfo, stream_id_), |
58 | | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::brpc::ChunkInfo, chunk_id_), |
59 | | 0, |
60 | | 1, |
61 | | }; |
62 | | static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
63 | | { 0, 7, sizeof(::brpc::ChunkInfo)}, |
64 | | }; |
65 | | |
66 | | static ::google::protobuf::Message const * const file_default_instances[] = { |
67 | | reinterpret_cast<const ::google::protobuf::Message*>(&::brpc::_ChunkInfo_default_instance_), |
68 | | }; |
69 | | |
70 | 0 | void protobuf_AssignDescriptors() { |
71 | 0 | AddDescriptors(); |
72 | 0 | AssignDescriptors( |
73 | 0 | "brpc/options.proto", schemas, file_default_instances, TableStruct::offsets, |
74 | 0 | file_level_metadata, file_level_enum_descriptors, NULL); |
75 | 0 | } |
76 | | |
77 | 0 | void protobuf_AssignDescriptorsOnce() { |
78 | 0 | static ::google::protobuf::internal::once_flag once; |
79 | 0 | ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors); |
80 | 0 | } |
81 | | |
82 | | void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD; |
83 | 0 | void protobuf_RegisterTypes(const ::std::string&) { |
84 | 0 | protobuf_AssignDescriptorsOnce(); |
85 | 0 | ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 1); |
86 | 0 | } |
87 | | |
88 | 2 | void AddDescriptorsImpl() { |
89 | 2 | InitDefaults(); |
90 | 2 | static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
91 | 2 | "\n\022brpc/options.proto\022\004brpc\032 google/proto" |
92 | 2 | "buf/descriptor.proto\"0\n\tChunkInfo\022\021\n\tstr" |
93 | 2 | "eam_id\030\001 \002(\003\022\020\n\010chunk_id\030\002 \002(\003*6\n\010TalkTy" |
94 | 2 | "pe\022\024\n\020TALK_TYPE_NORMAL\020\000\022\024\n\020TALK_TYPE_ON" |
95 | 2 | "EWAY\020\001*\200\001\n\016ConnectionType\022\033\n\027CONNECTION_" |
96 | 2 | "TYPE_UNKNOWN\020\000\022\032\n\026CONNECTION_TYPE_SINGLE" |
97 | 2 | "\020\001\022\032\n\026CONNECTION_TYPE_POOLED\020\002\022\031\n\025CONNEC" |
98 | 2 | "TION_TYPE_SHORT\020\004*\217\005\n\014ProtocolType\022\024\n\020PR" |
99 | 2 | "OTOCOL_UNKNOWN\020\000\022\026\n\022PROTOCOL_BAIDU_STD\020\001" |
100 | 2 | "\022\032\n\026PROTOCOL_STREAMING_RPC\020\002\022\027\n\023PROTOCOL" |
101 | 2 | "_HULU_PBRPC\020\003\022\027\n\023PROTOCOL_SOFA_PBRPC\020\004\022\021" |
102 | 2 | "\n\rPROTOCOL_RTMP\020\005\022\023\n\017PROTOCOL_THRIFT\020\006\022\021" |
103 | 2 | "\n\rPROTOCOL_HTTP\020\007\022\031\n\025PROTOCOL_PUBLIC_PBR" |
104 | 2 | "PC\020\010\022\027\n\023PROTOCOL_NOVA_PBRPC\020\t\022\022\n\016PROTOCO" |
105 | 2 | "L_REDIS\020\n\022\032\n\026PROTOCOL_NSHEAD_CLIENT\020\013\022\023\n" |
106 | 2 | "\017PROTOCOL_NSHEAD\020\014\022\027\n\023PROTOCOL_HADOOP_RP" |
107 | 2 | "C\020\r\022\036\n\032PROTOCOL_HADOOP_SERVER_RPC\020\016\022\022\n\016P" |
108 | 2 | "ROTOCOL_MONGO\020\017\022\032\n\026PROTOCOL_UBRPC_COMPAC" |
109 | 2 | "K\020\020\022\030\n\024PROTOCOL_DIDX_CLIENT\020\021\022\025\n\021PROTOCO" |
110 | 2 | "L_MEMCACHE\020\022\022\020\n\014PROTOCOL_ITP\020\023\022\032\n\026PROTOC" |
111 | 2 | "OL_NSHEAD_MCPACK\020\024\022\025\n\021PROTOCOL_DISP_IDL\020" |
112 | 2 | "\025\022\031\n\025PROTOCOL_ERSDA_CLIENT\020\026\022\032\n\026PROTOCOL" |
113 | 2 | "_UBRPC_MCPACK2\020\027\022\026\n\022PROTOCOL_CDS_AGENT\020\030" |
114 | 2 | "\022\020\n\014PROTOCOL_ESP\020\031\022\017\n\013PROTOCOL_H2\020\032*\207\001\n\014" |
115 | 2 | "CompressType\022\026\n\022COMPRESS_TYPE_NONE\020\000\022\030\n\024" |
116 | 2 | "COMPRESS_TYPE_SNAPPY\020\001\022\026\n\022COMPRESS_TYPE_" |
117 | 2 | "GZIP\020\002\022\026\n\022COMPRESS_TYPE_ZLIB\020\003\022\025\n\021COMPRE" |
118 | 2 | "SS_TYPE_LZ4\020\004*@\n\014ChecksumType\022\026\n\022CHECKSU" |
119 | 2 | "M_TYPE_NONE\020\000\022\030\n\024CHECKSUM_TYPE_CRC32C\020\001*" |
120 | 2 | "s\n\013ContentType\022\023\n\017CONTENT_TYPE_PB\020\000\022\025\n\021C" |
121 | 2 | "ONTENT_TYPE_JSON\020\001\022\033\n\027CONTENT_TYPE_PROTO" |
122 | 2 | "_JSON\020\002\022\033\n\027CONTENT_TYPE_PROTO_TEXT\020\003:A\n\017" |
123 | 2 | "service_timeout\022\037.google.protobuf.Servic" |
124 | 2 | "eOptions\030\220\277\005 \001(\003:\00510000:]\n\021request_talk_" |
125 | 2 | "type\022\036.google.protobuf.MethodOptions\030\221\277\005" |
126 | 2 | " \001(\0162\016.brpc.TalkType:\020TALK_TYPE_NORMAL:^" |
127 | 2 | "\n\022response_talk_type\022\036.google.protobuf.M" |
128 | 2 | "ethodOptions\030\222\277\005 \001(\0162\016.brpc.TalkType:\020TA" |
129 | 2 | "LK_TYPE_NORMAL:8\n\016method_timeout\022\036.googl" |
130 | 2 | "e.protobuf.MethodOptions\030\223\277\005 \001(\003:e\n\023requ" |
131 | 2 | "est_compression\022\036.google.protobuf.Method" |
132 | 2 | "Options\030\224\277\005 \001(\0162\022.brpc.CompressType:\022COM" |
133 | 2 | "PRESS_TYPE_NONE:f\n\024response_compression\022" |
134 | 2 | "\036.google.protobuf.MethodOptions\030\225\277\005 \001(\0162" |
135 | 2 | "\022.brpc.CompressType:\022COMPRESS_TYPE_NONEB" |
136 | 2 | "\023\n\010com.brpcB\007Options" |
137 | 2 | }; |
138 | 2 | ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( |
139 | 2 | descriptor, 1820); |
140 | 2 | ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( |
141 | 2 | "brpc/options.proto", &protobuf_RegisterTypes); |
142 | 2 | ::protobuf_google_2fprotobuf_2fdescriptor_2eproto::AddDescriptors(); |
143 | 2 | } |
144 | | |
145 | 12 | void AddDescriptors() { |
146 | 12 | static ::google::protobuf::internal::once_flag once; |
147 | 12 | ::google::protobuf::internal::call_once(once, AddDescriptorsImpl); |
148 | 12 | } |
149 | | // Force AddDescriptors() to be called at dynamic initialization time. |
150 | | struct StaticDescriptorInitializer { |
151 | 2 | StaticDescriptorInitializer() { |
152 | 2 | AddDescriptors(); |
153 | 2 | } |
154 | | } static_descriptor_initializer; |
155 | | } // namespace protobuf_brpc_2foptions_2eproto |
156 | | namespace brpc { |
157 | 0 | const ::google::protobuf::EnumDescriptor* TalkType_descriptor() { |
158 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
159 | 0 | return protobuf_brpc_2foptions_2eproto::file_level_enum_descriptors[0]; |
160 | 0 | } |
161 | 0 | bool TalkType_IsValid(int value) { |
162 | 0 | switch (value) { |
163 | 0 | case 0: |
164 | 0 | case 1: |
165 | 0 | return true; |
166 | 0 | default: |
167 | 0 | return false; |
168 | 0 | } |
169 | 0 | } |
170 | | |
171 | 0 | const ::google::protobuf::EnumDescriptor* ConnectionType_descriptor() { |
172 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
173 | 0 | return protobuf_brpc_2foptions_2eproto::file_level_enum_descriptors[1]; |
174 | 0 | } |
175 | 0 | bool ConnectionType_IsValid(int value) { |
176 | 0 | switch (value) { |
177 | 0 | case 0: |
178 | 0 | case 1: |
179 | 0 | case 2: |
180 | 0 | case 4: |
181 | 0 | return true; |
182 | 0 | default: |
183 | 0 | return false; |
184 | 0 | } |
185 | 0 | } |
186 | | |
187 | 0 | const ::google::protobuf::EnumDescriptor* ProtocolType_descriptor() { |
188 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
189 | 0 | return protobuf_brpc_2foptions_2eproto::file_level_enum_descriptors[2]; |
190 | 0 | } |
191 | 0 | bool ProtocolType_IsValid(int value) { |
192 | 0 | switch (value) { |
193 | 0 | case 0: |
194 | 0 | case 1: |
195 | 0 | case 2: |
196 | 0 | case 3: |
197 | 0 | case 4: |
198 | 0 | case 5: |
199 | 0 | case 6: |
200 | 0 | case 7: |
201 | 0 | case 8: |
202 | 0 | case 9: |
203 | 0 | case 10: |
204 | 0 | case 11: |
205 | 0 | case 12: |
206 | 0 | case 13: |
207 | 0 | case 14: |
208 | 0 | case 15: |
209 | 0 | case 16: |
210 | 0 | case 17: |
211 | 0 | case 18: |
212 | 0 | case 19: |
213 | 0 | case 20: |
214 | 0 | case 21: |
215 | 0 | case 22: |
216 | 0 | case 23: |
217 | 0 | case 24: |
218 | 0 | case 25: |
219 | 0 | case 26: |
220 | 0 | return true; |
221 | 0 | default: |
222 | 0 | return false; |
223 | 0 | } |
224 | 0 | } |
225 | | |
226 | 0 | const ::google::protobuf::EnumDescriptor* CompressType_descriptor() { |
227 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
228 | 0 | return protobuf_brpc_2foptions_2eproto::file_level_enum_descriptors[3]; |
229 | 0 | } |
230 | 0 | bool CompressType_IsValid(int value) { |
231 | 0 | switch (value) { |
232 | 0 | case 0: |
233 | 0 | case 1: |
234 | 0 | case 2: |
235 | 0 | case 3: |
236 | 0 | case 4: |
237 | 0 | return true; |
238 | 0 | default: |
239 | 0 | return false; |
240 | 0 | } |
241 | 0 | } |
242 | | |
243 | 0 | const ::google::protobuf::EnumDescriptor* ChecksumType_descriptor() { |
244 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
245 | 0 | return protobuf_brpc_2foptions_2eproto::file_level_enum_descriptors[4]; |
246 | 0 | } |
247 | 0 | bool ChecksumType_IsValid(int value) { |
248 | 0 | switch (value) { |
249 | 0 | case 0: |
250 | 0 | case 1: |
251 | 0 | return true; |
252 | 0 | default: |
253 | 0 | return false; |
254 | 0 | } |
255 | 0 | } |
256 | | |
257 | 0 | const ::google::protobuf::EnumDescriptor* ContentType_descriptor() { |
258 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
259 | 0 | return protobuf_brpc_2foptions_2eproto::file_level_enum_descriptors[5]; |
260 | 0 | } |
261 | 0 | bool ContentType_IsValid(int value) { |
262 | 0 | switch (value) { |
263 | 0 | case 0: |
264 | 0 | case 1: |
265 | 0 | case 2: |
266 | 0 | case 3: |
267 | 0 | return true; |
268 | 0 | default: |
269 | 0 | return false; |
270 | 0 | } |
271 | 0 | } |
272 | | |
273 | | |
274 | | // =================================================================== |
275 | | |
276 | 2 | void ChunkInfo::InitAsDefaultInstance() { |
277 | 2 | } |
278 | | #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
279 | | const int ChunkInfo::kStreamIdFieldNumber; |
280 | | const int ChunkInfo::kChunkIdFieldNumber; |
281 | | #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
282 | | |
283 | | ChunkInfo::ChunkInfo() |
284 | 2 | : ::google::protobuf::Message(), _internal_metadata_(NULL) { |
285 | 2 | ::google::protobuf::internal::InitSCC( |
286 | 2 | &protobuf_brpc_2foptions_2eproto::scc_info_ChunkInfo.base); |
287 | 2 | SharedCtor(); |
288 | | // @@protoc_insertion_point(constructor:brpc.ChunkInfo) |
289 | 2 | } |
290 | | ChunkInfo::ChunkInfo(const ChunkInfo& from) |
291 | 0 | : ::google::protobuf::Message(), |
292 | 0 | _internal_metadata_(NULL), |
293 | 0 | _has_bits_(from._has_bits_) { |
294 | 0 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
295 | 0 | ::memcpy(&stream_id_, &from.stream_id_, |
296 | 0 | static_cast<size_t>(reinterpret_cast<char*>(&chunk_id_) - |
297 | 0 | reinterpret_cast<char*>(&stream_id_)) + sizeof(chunk_id_)); |
298 | | // @@protoc_insertion_point(copy_constructor:brpc.ChunkInfo) |
299 | 0 | } |
300 | | |
301 | 2 | void ChunkInfo::SharedCtor() { |
302 | 2 | ::memset(&stream_id_, 0, static_cast<size_t>( |
303 | 2 | reinterpret_cast<char*>(&chunk_id_) - |
304 | 2 | reinterpret_cast<char*>(&stream_id_)) + sizeof(chunk_id_)); |
305 | 2 | } |
306 | | |
307 | 0 | ChunkInfo::~ChunkInfo() { |
308 | | // @@protoc_insertion_point(destructor:brpc.ChunkInfo) |
309 | 0 | SharedDtor(); |
310 | 0 | } |
311 | | |
312 | 0 | void ChunkInfo::SharedDtor() { |
313 | 0 | } |
314 | | |
315 | 0 | void ChunkInfo::SetCachedSize(int size) const { |
316 | 0 | _cached_size_.Set(size); |
317 | 0 | } |
318 | 0 | const ::google::protobuf::Descriptor* ChunkInfo::descriptor() { |
319 | 0 | ::protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
320 | 0 | return ::protobuf_brpc_2foptions_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; |
321 | 0 | } |
322 | | |
323 | 0 | const ChunkInfo& ChunkInfo::default_instance() { |
324 | 0 | ::google::protobuf::internal::InitSCC(&protobuf_brpc_2foptions_2eproto::scc_info_ChunkInfo.base); |
325 | 0 | return *internal_default_instance(); |
326 | 0 | } |
327 | | |
328 | | |
329 | 0 | void ChunkInfo::Clear() { |
330 | | // @@protoc_insertion_point(message_clear_start:brpc.ChunkInfo) |
331 | 0 | ::google::protobuf::uint32 cached_has_bits = 0; |
332 | | // Prevent compiler warnings about cached_has_bits being unused |
333 | 0 | (void) cached_has_bits; |
334 | |
|
335 | 0 | cached_has_bits = _has_bits_[0]; |
336 | 0 | if (cached_has_bits & 3u) { |
337 | 0 | ::memset(&stream_id_, 0, static_cast<size_t>( |
338 | 0 | reinterpret_cast<char*>(&chunk_id_) - |
339 | 0 | reinterpret_cast<char*>(&stream_id_)) + sizeof(chunk_id_)); |
340 | 0 | } |
341 | 0 | _has_bits_.Clear(); |
342 | 0 | _internal_metadata_.Clear(); |
343 | 0 | } |
344 | | |
345 | | bool ChunkInfo::MergePartialFromCodedStream( |
346 | 0 | ::google::protobuf::io::CodedInputStream* input) { |
347 | 0 | #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure |
348 | 0 | ::google::protobuf::uint32 tag; |
349 | | // @@protoc_insertion_point(parse_start:brpc.ChunkInfo) |
350 | 0 | for (;;) { |
351 | 0 | ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
352 | 0 | tag = p.first; |
353 | 0 | if (!p.second) goto handle_unusual; |
354 | 0 | switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
355 | | // required int64 stream_id = 1; |
356 | 0 | case 1: { |
357 | 0 | if (static_cast< ::google::protobuf::uint8>(tag) == |
358 | 0 | static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) { |
359 | 0 | set_has_stream_id(); |
360 | 0 | DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
361 | 0 | ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>( |
362 | 0 | input, &stream_id_))); |
363 | 0 | } else { |
364 | 0 | goto handle_unusual; |
365 | 0 | } |
366 | 0 | break; |
367 | 0 | } |
368 | | |
369 | | // required int64 chunk_id = 2; |
370 | 0 | case 2: { |
371 | 0 | if (static_cast< ::google::protobuf::uint8>(tag) == |
372 | 0 | static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) { |
373 | 0 | set_has_chunk_id(); |
374 | 0 | DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
375 | 0 | ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>( |
376 | 0 | input, &chunk_id_))); |
377 | 0 | } else { |
378 | 0 | goto handle_unusual; |
379 | 0 | } |
380 | 0 | break; |
381 | 0 | } |
382 | | |
383 | 0 | default: { |
384 | 0 | handle_unusual: |
385 | 0 | if (tag == 0) { |
386 | 0 | goto success; |
387 | 0 | } |
388 | 0 | DO_(::google::protobuf::internal::WireFormat::SkipField( |
389 | 0 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
390 | 0 | break; |
391 | 0 | } |
392 | 0 | } |
393 | 0 | } |
394 | 0 | success: |
395 | | // @@protoc_insertion_point(parse_success:brpc.ChunkInfo) |
396 | 0 | return true; |
397 | 0 | failure: |
398 | | // @@protoc_insertion_point(parse_failure:brpc.ChunkInfo) |
399 | 0 | return false; |
400 | 0 | #undef DO_ |
401 | 0 | } |
402 | | |
403 | | void ChunkInfo::SerializeWithCachedSizes( |
404 | 0 | ::google::protobuf::io::CodedOutputStream* output) const { |
405 | | // @@protoc_insertion_point(serialize_start:brpc.ChunkInfo) |
406 | 0 | ::google::protobuf::uint32 cached_has_bits = 0; |
407 | 0 | (void) cached_has_bits; |
408 | |
|
409 | 0 | cached_has_bits = _has_bits_[0]; |
410 | | // required int64 stream_id = 1; |
411 | 0 | if (cached_has_bits & 0x00000001u) { |
412 | 0 | ::google::protobuf::internal::WireFormatLite::WriteInt64(1, this->stream_id(), output); |
413 | 0 | } |
414 | | |
415 | | // required int64 chunk_id = 2; |
416 | 0 | if (cached_has_bits & 0x00000002u) { |
417 | 0 | ::google::protobuf::internal::WireFormatLite::WriteInt64(2, this->chunk_id(), output); |
418 | 0 | } |
419 | |
|
420 | 0 | if (_internal_metadata_.have_unknown_fields()) { |
421 | 0 | ::google::protobuf::internal::WireFormat::SerializeUnknownFields( |
422 | 0 | _internal_metadata_.unknown_fields(), output); |
423 | 0 | } |
424 | | // @@protoc_insertion_point(serialize_end:brpc.ChunkInfo) |
425 | 0 | } |
426 | | |
427 | | ::google::protobuf::uint8* ChunkInfo::InternalSerializeWithCachedSizesToArray( |
428 | 0 | bool deterministic, ::google::protobuf::uint8* target) const { |
429 | 0 | (void)deterministic; // Unused |
430 | | // @@protoc_insertion_point(serialize_to_array_start:brpc.ChunkInfo) |
431 | 0 | ::google::protobuf::uint32 cached_has_bits = 0; |
432 | 0 | (void) cached_has_bits; |
433 | |
|
434 | 0 | cached_has_bits = _has_bits_[0]; |
435 | | // required int64 stream_id = 1; |
436 | 0 | if (cached_has_bits & 0x00000001u) { |
437 | 0 | target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(1, this->stream_id(), target); |
438 | 0 | } |
439 | | |
440 | | // required int64 chunk_id = 2; |
441 | 0 | if (cached_has_bits & 0x00000002u) { |
442 | 0 | target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(2, this->chunk_id(), target); |
443 | 0 | } |
444 | |
|
445 | 0 | if (_internal_metadata_.have_unknown_fields()) { |
446 | 0 | target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( |
447 | 0 | _internal_metadata_.unknown_fields(), target); |
448 | 0 | } |
449 | | // @@protoc_insertion_point(serialize_to_array_end:brpc.ChunkInfo) |
450 | 0 | return target; |
451 | 0 | } |
452 | | |
453 | 0 | size_t ChunkInfo::RequiredFieldsByteSizeFallback() const { |
454 | | // @@protoc_insertion_point(required_fields_byte_size_fallback_start:brpc.ChunkInfo) |
455 | 0 | size_t total_size = 0; |
456 | |
|
457 | 0 | if (has_stream_id()) { |
458 | | // required int64 stream_id = 1; |
459 | 0 | total_size += 1 + |
460 | 0 | ::google::protobuf::internal::WireFormatLite::Int64Size( |
461 | 0 | this->stream_id()); |
462 | 0 | } |
463 | |
|
464 | 0 | if (has_chunk_id()) { |
465 | | // required int64 chunk_id = 2; |
466 | 0 | total_size += 1 + |
467 | 0 | ::google::protobuf::internal::WireFormatLite::Int64Size( |
468 | 0 | this->chunk_id()); |
469 | 0 | } |
470 | |
|
471 | 0 | return total_size; |
472 | 0 | } |
473 | 0 | size_t ChunkInfo::ByteSizeLong() const { |
474 | | // @@protoc_insertion_point(message_byte_size_start:brpc.ChunkInfo) |
475 | 0 | size_t total_size = 0; |
476 | |
|
477 | 0 | if (_internal_metadata_.have_unknown_fields()) { |
478 | 0 | total_size += |
479 | 0 | ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( |
480 | 0 | _internal_metadata_.unknown_fields()); |
481 | 0 | } |
482 | 0 | if (((_has_bits_[0] & 0x00000003) ^ 0x00000003) == 0) { // All required fields are present. |
483 | | // required int64 stream_id = 1; |
484 | 0 | total_size += 1 + |
485 | 0 | ::google::protobuf::internal::WireFormatLite::Int64Size( |
486 | 0 | this->stream_id()); |
487 | | |
488 | | // required int64 chunk_id = 2; |
489 | 0 | total_size += 1 + |
490 | 0 | ::google::protobuf::internal::WireFormatLite::Int64Size( |
491 | 0 | this->chunk_id()); |
492 | |
|
493 | 0 | } else { |
494 | 0 | total_size += RequiredFieldsByteSizeFallback(); |
495 | 0 | } |
496 | 0 | int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); |
497 | 0 | SetCachedSize(cached_size); |
498 | 0 | return total_size; |
499 | 0 | } |
500 | | |
501 | 0 | void ChunkInfo::MergeFrom(const ::google::protobuf::Message& from) { |
502 | | // @@protoc_insertion_point(generalized_merge_from_start:brpc.ChunkInfo) |
503 | 0 | GOOGLE_DCHECK_NE(&from, this); |
504 | 0 | const ChunkInfo* source = |
505 | 0 | ::google::protobuf::internal::DynamicCastToGenerated<const ChunkInfo>( |
506 | 0 | &from); |
507 | 0 | if (source == NULL) { |
508 | | // @@protoc_insertion_point(generalized_merge_from_cast_fail:brpc.ChunkInfo) |
509 | 0 | ::google::protobuf::internal::ReflectionOps::Merge(from, this); |
510 | 0 | } else { |
511 | | // @@protoc_insertion_point(generalized_merge_from_cast_success:brpc.ChunkInfo) |
512 | 0 | MergeFrom(*source); |
513 | 0 | } |
514 | 0 | } |
515 | | |
516 | 0 | void ChunkInfo::MergeFrom(const ChunkInfo& from) { |
517 | | // @@protoc_insertion_point(class_specific_merge_from_start:brpc.ChunkInfo) |
518 | 0 | GOOGLE_DCHECK_NE(&from, this); |
519 | 0 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
520 | 0 | ::google::protobuf::uint32 cached_has_bits = 0; |
521 | 0 | (void) cached_has_bits; |
522 | |
|
523 | 0 | cached_has_bits = from._has_bits_[0]; |
524 | 0 | if (cached_has_bits & 3u) { |
525 | 0 | if (cached_has_bits & 0x00000001u) { |
526 | 0 | stream_id_ = from.stream_id_; |
527 | 0 | } |
528 | 0 | if (cached_has_bits & 0x00000002u) { |
529 | 0 | chunk_id_ = from.chunk_id_; |
530 | 0 | } |
531 | 0 | _has_bits_[0] |= cached_has_bits; |
532 | 0 | } |
533 | 0 | } |
534 | | |
535 | 0 | void ChunkInfo::CopyFrom(const ::google::protobuf::Message& from) { |
536 | | // @@protoc_insertion_point(generalized_copy_from_start:brpc.ChunkInfo) |
537 | 0 | if (&from == this) return; |
538 | 0 | Clear(); |
539 | 0 | MergeFrom(from); |
540 | 0 | } |
541 | | |
542 | 0 | void ChunkInfo::CopyFrom(const ChunkInfo& from) { |
543 | | // @@protoc_insertion_point(class_specific_copy_from_start:brpc.ChunkInfo) |
544 | 0 | if (&from == this) return; |
545 | 0 | Clear(); |
546 | 0 | MergeFrom(from); |
547 | 0 | } |
548 | | |
549 | 0 | bool ChunkInfo::IsInitialized() const { |
550 | 0 | if ((_has_bits_[0] & 0x00000003) != 0x00000003) return false; |
551 | 0 | return true; |
552 | 0 | } |
553 | | |
554 | 0 | void ChunkInfo::Swap(ChunkInfo* other) { |
555 | 0 | if (other == this) return; |
556 | 0 | InternalSwap(other); |
557 | 0 | } |
558 | 0 | void ChunkInfo::InternalSwap(ChunkInfo* other) { |
559 | 0 | using std::swap; |
560 | 0 | swap(stream_id_, other->stream_id_); |
561 | 0 | swap(chunk_id_, other->chunk_id_); |
562 | 0 | swap(_has_bits_[0], other->_has_bits_[0]); |
563 | 0 | _internal_metadata_.Swap(&other->_internal_metadata_); |
564 | 0 | } |
565 | | |
566 | 0 | ::google::protobuf::Metadata ChunkInfo::GetMetadata() const { |
567 | 0 | protobuf_brpc_2foptions_2eproto::protobuf_AssignDescriptorsOnce(); |
568 | 0 | return ::protobuf_brpc_2foptions_2eproto::file_level_metadata[kIndexInFileMessages]; |
569 | 0 | } |
570 | | |
571 | | ::google::protobuf::internal::ExtensionIdentifier< ::google::protobuf::ServiceOptions, |
572 | | ::google::protobuf::internal::PrimitiveTypeTraits< ::google::protobuf::int64 >, 3, false > |
573 | | service_timeout(kServiceTimeoutFieldNumber, GOOGLE_LONGLONG(10000)); |
574 | | ::google::protobuf::internal::ExtensionIdentifier< ::google::protobuf::MethodOptions, |
575 | | ::google::protobuf::internal::EnumTypeTraits< ::brpc::TalkType, ::brpc::TalkType_IsValid>, 14, false > |
576 | | request_talk_type(kRequestTalkTypeFieldNumber, static_cast< ::brpc::TalkType >(0)); |
577 | | ::google::protobuf::internal::ExtensionIdentifier< ::google::protobuf::MethodOptions, |
578 | | ::google::protobuf::internal::EnumTypeTraits< ::brpc::TalkType, ::brpc::TalkType_IsValid>, 14, false > |
579 | | response_talk_type(kResponseTalkTypeFieldNumber, static_cast< ::brpc::TalkType >(0)); |
580 | | ::google::protobuf::internal::ExtensionIdentifier< ::google::protobuf::MethodOptions, |
581 | | ::google::protobuf::internal::PrimitiveTypeTraits< ::google::protobuf::int64 >, 3, false > |
582 | | method_timeout(kMethodTimeoutFieldNumber, GOOGLE_LONGLONG(0)); |
583 | | ::google::protobuf::internal::ExtensionIdentifier< ::google::protobuf::MethodOptions, |
584 | | ::google::protobuf::internal::EnumTypeTraits< ::brpc::CompressType, ::brpc::CompressType_IsValid>, 14, false > |
585 | | request_compression(kRequestCompressionFieldNumber, static_cast< ::brpc::CompressType >(0)); |
586 | | ::google::protobuf::internal::ExtensionIdentifier< ::google::protobuf::MethodOptions, |
587 | | ::google::protobuf::internal::EnumTypeTraits< ::brpc::CompressType, ::brpc::CompressType_IsValid>, 14, false > |
588 | | response_compression(kResponseCompressionFieldNumber, static_cast< ::brpc::CompressType >(0)); |
589 | | |
590 | | // @@protoc_insertion_point(namespace_scope) |
591 | | } // namespace brpc |
592 | | namespace google { |
593 | | namespace protobuf { |
594 | 0 | template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::brpc::ChunkInfo* Arena::CreateMaybeMessage< ::brpc::ChunkInfo >(Arena* arena) { |
595 | 0 | return Arena::CreateInternal< ::brpc::ChunkInfo >(arena); |
596 | 0 | } |
597 | | } // namespace protobuf |
598 | | } // namespace google |
599 | | |
600 | | // @@protoc_insertion_point(global_scope) |