Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! |
| 2 | // source: google/protobuf/api.proto |
| 3 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 4 | #include <google/protobuf/api.pb.h> |
| 5 | |
| 6 | #include <algorithm> |
| 7 | |
| 8 | #include <google/protobuf/stubs/common.h> |
| 9 | #include <google/protobuf/stubs/port.h> |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 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> |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 16 | // This is a temporary google only hack |
| 17 | #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS |
| 18 | #include "third_party/protobuf/version.h" |
| 19 | #endif |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 20 | // @@protoc_insertion_point(includes) |
| 21 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 22 | namespace protobuf_google_2fprotobuf_2fapi_2eproto { |
| 23 | extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fapi_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Mixin; |
| 24 | extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fapi_2eproto ::google::protobuf::internal::SCCInfo<1> scc_info_Method; |
| 25 | } // namespace protobuf_google_2fprotobuf_2fapi_2eproto |
| 26 | namespace protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto { |
| 27 | extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_SourceContext; |
| 28 | } // namespace protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto |
| 29 | namespace protobuf_google_2fprotobuf_2ftype_2eproto { |
| 30 | extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2ftype_2eproto ::google::protobuf::internal::SCCInfo<1> scc_info_Option; |
| 31 | } // namespace protobuf_google_2fprotobuf_2ftype_2eproto |
| 32 | namespace google { |
| 33 | namespace protobuf { |
| 34 | class ApiDefaultTypeInternal { |
| 35 | public: |
| 36 | ::google::protobuf::internal::ExplicitlyConstructed<Api> |
| 37 | _instance; |
| 38 | } _Api_default_instance_; |
| 39 | class MethodDefaultTypeInternal { |
| 40 | public: |
| 41 | ::google::protobuf::internal::ExplicitlyConstructed<Method> |
| 42 | _instance; |
| 43 | } _Method_default_instance_; |
| 44 | class MixinDefaultTypeInternal { |
| 45 | public: |
| 46 | ::google::protobuf::internal::ExplicitlyConstructed<Mixin> |
| 47 | _instance; |
| 48 | } _Mixin_default_instance_; |
| 49 | } // namespace protobuf |
| 50 | } // namespace google |
| 51 | namespace protobuf_google_2fprotobuf_2fapi_2eproto { |
| 52 | static void InitDefaultsApi() { |
| 53 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
| 54 | |
| 55 | { |
| 56 | void* ptr = &::google::protobuf::_Api_default_instance_; |
| 57 | new (ptr) ::google::protobuf::Api(); |
| 58 | ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); |
| 59 | } |
| 60 | ::google::protobuf::Api::InitAsDefaultInstance(); |
| 61 | } |
| 62 | |
| 63 | LIBPROTOBUF_EXPORT ::google::protobuf::internal::SCCInfo<4> scc_info_Api = |
| 64 | {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 4, InitDefaultsApi}, { |
| 65 | &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Method.base, |
| 66 | &protobuf_google_2fprotobuf_2ftype_2eproto::scc_info_Option.base, |
| 67 | &protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto::scc_info_SourceContext.base, |
| 68 | &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Mixin.base,}}; |
| 69 | |
| 70 | static void InitDefaultsMethod() { |
| 71 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
| 72 | |
| 73 | { |
| 74 | void* ptr = &::google::protobuf::_Method_default_instance_; |
| 75 | new (ptr) ::google::protobuf::Method(); |
| 76 | ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); |
| 77 | } |
| 78 | ::google::protobuf::Method::InitAsDefaultInstance(); |
| 79 | } |
| 80 | |
| 81 | LIBPROTOBUF_EXPORT ::google::protobuf::internal::SCCInfo<1> scc_info_Method = |
| 82 | {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsMethod}, { |
| 83 | &protobuf_google_2fprotobuf_2ftype_2eproto::scc_info_Option.base,}}; |
| 84 | |
| 85 | static void InitDefaultsMixin() { |
| 86 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
| 87 | |
| 88 | { |
| 89 | void* ptr = &::google::protobuf::_Mixin_default_instance_; |
| 90 | new (ptr) ::google::protobuf::Mixin(); |
| 91 | ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); |
| 92 | } |
| 93 | ::google::protobuf::Mixin::InitAsDefaultInstance(); |
| 94 | } |
| 95 | |
| 96 | LIBPROTOBUF_EXPORT ::google::protobuf::internal::SCCInfo<0> scc_info_Mixin = |
| 97 | {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsMixin}, {}}; |
| 98 | |
| 99 | void InitDefaults() { |
| 100 | ::google::protobuf::internal::InitSCC(&scc_info_Api.base); |
| 101 | ::google::protobuf::internal::InitSCC(&scc_info_Method.base); |
| 102 | ::google::protobuf::internal::InitSCC(&scc_info_Mixin.base); |
| 103 | } |
| 104 | |
| 105 | ::google::protobuf::Metadata file_level_metadata[3]; |
| 106 | |
| 107 | const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
| 108 | ~0u, // no _has_bits_ |
| 109 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, _internal_metadata_), |
| 110 | ~0u, // no _extensions_ |
| 111 | ~0u, // no _oneof_case_ |
| 112 | ~0u, // no _weak_field_map_ |
| 113 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, name_), |
| 114 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, methods_), |
| 115 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, options_), |
| 116 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, version_), |
| 117 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, source_context_), |
| 118 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, mixins_), |
| 119 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Api, syntax_), |
| 120 | ~0u, // no _has_bits_ |
| 121 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, _internal_metadata_), |
| 122 | ~0u, // no _extensions_ |
| 123 | ~0u, // no _oneof_case_ |
| 124 | ~0u, // no _weak_field_map_ |
| 125 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, name_), |
| 126 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, request_type_url_), |
| 127 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, request_streaming_), |
| 128 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, response_type_url_), |
| 129 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, response_streaming_), |
| 130 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, options_), |
| 131 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Method, syntax_), |
| 132 | ~0u, // no _has_bits_ |
| 133 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Mixin, _internal_metadata_), |
| 134 | ~0u, // no _extensions_ |
| 135 | ~0u, // no _oneof_case_ |
| 136 | ~0u, // no _weak_field_map_ |
| 137 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Mixin, name_), |
| 138 | GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Mixin, root_), |
| 139 | }; |
| 140 | static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
| 141 | { 0, -1, sizeof(::google::protobuf::Api)}, |
| 142 | { 12, -1, sizeof(::google::protobuf::Method)}, |
| 143 | { 24, -1, sizeof(::google::protobuf::Mixin)}, |
| 144 | }; |
| 145 | |
| 146 | static ::google::protobuf::Message const * const file_default_instances[] = { |
| 147 | reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::_Api_default_instance_), |
| 148 | reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::_Method_default_instance_), |
| 149 | reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::_Mixin_default_instance_), |
| 150 | }; |
| 151 | |
| 152 | void protobuf_AssignDescriptors() { |
| 153 | AddDescriptors(); |
| 154 | AssignDescriptors( |
| 155 | "google/protobuf/api.proto", schemas, file_default_instances, TableStruct::offsets, |
| 156 | file_level_metadata, NULL, NULL); |
| 157 | } |
| 158 | |
| 159 | void protobuf_AssignDescriptorsOnce() { |
| 160 | static ::google::protobuf::internal::once_flag once; |
| 161 | ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors); |
| 162 | } |
| 163 | |
| 164 | void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD; |
| 165 | void protobuf_RegisterTypes(const ::std::string&) { |
| 166 | protobuf_AssignDescriptorsOnce(); |
| 167 | ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 3); |
| 168 | } |
| 169 | |
| 170 | void AddDescriptorsImpl() { |
| 171 | InitDefaults(); |
| 172 | static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { |
| 173 | "\n\031google/protobuf/api.proto\022\017google.prot" |
| 174 | "obuf\032$google/protobuf/source_context.pro" |
| 175 | "to\032\032google/protobuf/type.proto\"\201\002\n\003Api\022\014" |
| 176 | "\n\004name\030\001 \001(\t\022(\n\007methods\030\002 \003(\0132\027.google.p" |
| 177 | "rotobuf.Method\022(\n\007options\030\003 \003(\0132\027.google" |
| 178 | ".protobuf.Option\022\017\n\007version\030\004 \001(\t\0226\n\016sou" |
| 179 | "rce_context\030\005 \001(\0132\036.google.protobuf.Sour" |
| 180 | "ceContext\022&\n\006mixins\030\006 \003(\0132\026.google.proto" |
| 181 | "buf.Mixin\022\'\n\006syntax\030\007 \001(\0162\027.google.proto" |
| 182 | "buf.Syntax\"\325\001\n\006Method\022\014\n\004name\030\001 \001(\t\022\030\n\020r" |
| 183 | "equest_type_url\030\002 \001(\t\022\031\n\021request_streami" |
| 184 | "ng\030\003 \001(\010\022\031\n\021response_type_url\030\004 \001(\t\022\032\n\022r" |
| 185 | "esponse_streaming\030\005 \001(\010\022(\n\007options\030\006 \003(\013" |
| 186 | "2\027.google.protobuf.Option\022\'\n\006syntax\030\007 \001(" |
| 187 | "\0162\027.google.protobuf.Syntax\"#\n\005Mixin\022\014\n\004n" |
| 188 | "ame\030\001 \001(\t\022\014\n\004root\030\002 \001(\tBu\n\023com.google.pr" |
| 189 | "otobufB\010ApiProtoP\001Z+google.golang.org/ge" |
| 190 | "nproto/protobuf/api;api\242\002\003GPB\252\002\036Google.P" |
| 191 | "rotobuf.WellKnownTypesb\006proto3" |
| 192 | }; |
| 193 | ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( |
| 194 | descriptor, 750); |
| 195 | ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( |
| 196 | "google/protobuf/api.proto", &protobuf_RegisterTypes); |
| 197 | ::protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto::AddDescriptors(); |
| 198 | ::protobuf_google_2fprotobuf_2ftype_2eproto::AddDescriptors(); |
| 199 | } |
| 200 | |
| 201 | void AddDescriptors() { |
| 202 | static ::google::protobuf::internal::once_flag once; |
| 203 | ::google::protobuf::internal::call_once(once, AddDescriptorsImpl); |
| 204 | } |
| 205 | // Force AddDescriptors() to be called at dynamic initialization time. |
| 206 | struct StaticDescriptorInitializer { |
| 207 | StaticDescriptorInitializer() { |
| 208 | AddDescriptors(); |
| 209 | } |
| 210 | } static_descriptor_initializer; |
| 211 | } // namespace protobuf_google_2fprotobuf_2fapi_2eproto |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 212 | namespace google { |
| 213 | namespace protobuf { |
| 214 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 215 | // =================================================================== |
| 216 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 217 | void Api::InitAsDefaultInstance() { |
| 218 | ::google::protobuf::_Api_default_instance_._instance.get_mutable()->source_context_ = const_cast< ::google::protobuf::SourceContext*>( |
| 219 | ::google::protobuf::SourceContext::internal_default_instance()); |
| 220 | } |
| 221 | void Api::clear_options() { |
| 222 | options_.Clear(); |
| 223 | } |
| 224 | void Api::clear_source_context() { |
| 225 | if (GetArenaNoVirtual() == NULL && source_context_ != NULL) { |
| 226 | delete source_context_; |
| 227 | } |
| 228 | source_context_ = NULL; |
| 229 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 230 | #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
| 231 | const int Api::kNameFieldNumber; |
| 232 | const int Api::kMethodsFieldNumber; |
| 233 | const int Api::kOptionsFieldNumber; |
| 234 | const int Api::kVersionFieldNumber; |
| 235 | const int Api::kSourceContextFieldNumber; |
| 236 | const int Api::kMixinsFieldNumber; |
| 237 | const int Api::kSyntaxFieldNumber; |
| 238 | #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
| 239 | |
| 240 | Api::Api() |
| 241 | : ::google::protobuf::Message(), _internal_metadata_(NULL) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 242 | ::google::protobuf::internal::InitSCC( |
| 243 | &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Api.base); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 244 | SharedCtor(); |
| 245 | // @@protoc_insertion_point(constructor:google.protobuf.Api) |
| 246 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 247 | Api::Api(const Api& from) |
| 248 | : ::google::protobuf::Message(), |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 249 | _internal_metadata_(NULL), |
| 250 | methods_(from.methods_), |
| 251 | options_(from.options_), |
| 252 | mixins_(from.mixins_) { |
| 253 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
| 254 | name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 255 | if (from.name().size() > 0) { |
| 256 | name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_); |
| 257 | } |
| 258 | version_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 259 | if (from.version().size() > 0) { |
| 260 | version_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.version_); |
| 261 | } |
| 262 | if (from.has_source_context()) { |
| 263 | source_context_ = new ::google::protobuf::SourceContext(*from.source_context_); |
| 264 | } else { |
| 265 | source_context_ = NULL; |
| 266 | } |
| 267 | syntax_ = from.syntax_; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 268 | // @@protoc_insertion_point(copy_constructor:google.protobuf.Api) |
| 269 | } |
| 270 | |
| 271 | void Api::SharedCtor() { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 272 | name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 273 | version_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 274 | ::memset(&source_context_, 0, static_cast<size_t>( |
| 275 | reinterpret_cast<char*>(&syntax_) - |
| 276 | reinterpret_cast<char*>(&source_context_)) + sizeof(syntax_)); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 277 | } |
| 278 | |
| 279 | Api::~Api() { |
| 280 | // @@protoc_insertion_point(destructor:google.protobuf.Api) |
| 281 | SharedDtor(); |
| 282 | } |
| 283 | |
| 284 | void Api::SharedDtor() { |
| 285 | name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 286 | version_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 287 | if (this != internal_default_instance()) delete source_context_; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 288 | } |
| 289 | |
| 290 | void Api::SetCachedSize(int size) const { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 291 | _cached_size_.Set(size); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 292 | } |
| 293 | const ::google::protobuf::Descriptor* Api::descriptor() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 294 | ::protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce(); |
| 295 | return ::protobuf_google_2fprotobuf_2fapi_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 296 | } |
| 297 | |
| 298 | const Api& Api::default_instance() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 299 | ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Api.base); |
| 300 | return *internal_default_instance(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 301 | } |
| 302 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 303 | |
| 304 | void Api::Clear() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 305 | // @@protoc_insertion_point(message_clear_start:google.protobuf.Api) |
| 306 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 307 | // Prevent compiler warnings about cached_has_bits being unused |
| 308 | (void) cached_has_bits; |
| 309 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 310 | methods_.Clear(); |
| 311 | options_.Clear(); |
| 312 | mixins_.Clear(); |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 313 | name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 314 | version_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 315 | if (GetArenaNoVirtual() == NULL && source_context_ != NULL) { |
| 316 | delete source_context_; |
| 317 | } |
| 318 | source_context_ = NULL; |
| 319 | syntax_ = 0; |
| 320 | _internal_metadata_.Clear(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 321 | } |
| 322 | |
| 323 | bool Api::MergePartialFromCodedStream( |
| 324 | ::google::protobuf::io::CodedInputStream* input) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 325 | #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 326 | ::google::protobuf::uint32 tag; |
| 327 | // @@protoc_insertion_point(parse_start:google.protobuf.Api) |
| 328 | for (;;) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 329 | ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 330 | tag = p.first; |
| 331 | if (!p.second) goto handle_unusual; |
| 332 | switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 333 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 334 | case 1: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 335 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 336 | static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 337 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 338 | input, this->mutable_name())); |
| 339 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 340 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 341 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 342 | "google.protobuf.Api.name")); |
| 343 | } else { |
| 344 | goto handle_unusual; |
| 345 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 346 | break; |
| 347 | } |
| 348 | |
| 349 | // repeated .google.protobuf.Method methods = 2; |
| 350 | case 2: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 351 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 352 | static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { |
| 353 | DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 354 | input, add_methods())); |
| 355 | } else { |
| 356 | goto handle_unusual; |
| 357 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 358 | break; |
| 359 | } |
| 360 | |
| 361 | // repeated .google.protobuf.Option options = 3; |
| 362 | case 3: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 363 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 364 | static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) { |
| 365 | DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 366 | input, add_options())); |
| 367 | } else { |
| 368 | goto handle_unusual; |
| 369 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 370 | break; |
| 371 | } |
| 372 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 373 | // string version = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 374 | case 4: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 375 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 376 | static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 377 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 378 | input, this->mutable_version())); |
| 379 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 380 | this->version().data(), static_cast<int>(this->version().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 381 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 382 | "google.protobuf.Api.version")); |
| 383 | } else { |
| 384 | goto handle_unusual; |
| 385 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 386 | break; |
| 387 | } |
| 388 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 389 | // .google.protobuf.SourceContext source_context = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 390 | case 5: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 391 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 392 | static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) { |
| 393 | DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 394 | input, mutable_source_context())); |
| 395 | } else { |
| 396 | goto handle_unusual; |
| 397 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 398 | break; |
| 399 | } |
| 400 | |
| 401 | // repeated .google.protobuf.Mixin mixins = 6; |
| 402 | case 6: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 403 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 404 | static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { |
| 405 | DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 406 | input, add_mixins())); |
| 407 | } else { |
| 408 | goto handle_unusual; |
| 409 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 410 | break; |
| 411 | } |
| 412 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 413 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 414 | case 7: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 415 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 416 | static_cast< ::google::protobuf::uint8>(56u /* 56 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 417 | int value; |
| 418 | DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| 419 | int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( |
| 420 | input, &value))); |
| 421 | set_syntax(static_cast< ::google::protobuf::Syntax >(value)); |
| 422 | } else { |
| 423 | goto handle_unusual; |
| 424 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 425 | break; |
| 426 | } |
| 427 | |
| 428 | default: { |
| 429 | handle_unusual: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 430 | if (tag == 0) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 431 | goto success; |
| 432 | } |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 433 | DO_(::google::protobuf::internal::WireFormat::SkipField( |
| 434 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 435 | break; |
| 436 | } |
| 437 | } |
| 438 | } |
| 439 | success: |
| 440 | // @@protoc_insertion_point(parse_success:google.protobuf.Api) |
| 441 | return true; |
| 442 | failure: |
| 443 | // @@protoc_insertion_point(parse_failure:google.protobuf.Api) |
| 444 | return false; |
| 445 | #undef DO_ |
| 446 | } |
| 447 | |
| 448 | void Api::SerializeWithCachedSizes( |
| 449 | ::google::protobuf::io::CodedOutputStream* output) const { |
| 450 | // @@protoc_insertion_point(serialize_start:google.protobuf.Api) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 451 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 452 | (void) cached_has_bits; |
| 453 | |
| 454 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 455 | if (this->name().size() > 0) { |
| 456 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 457 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 458 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 459 | "google.protobuf.Api.name"); |
| 460 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 461 | 1, this->name(), output); |
| 462 | } |
| 463 | |
| 464 | // repeated .google.protobuf.Method methods = 2; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 465 | for (unsigned int i = 0, |
| 466 | n = static_cast<unsigned int>(this->methods_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 467 | ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 468 | 2, |
| 469 | this->methods(static_cast<int>(i)), |
| 470 | output); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 471 | } |
| 472 | |
| 473 | // repeated .google.protobuf.Option options = 3; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 474 | for (unsigned int i = 0, |
| 475 | n = static_cast<unsigned int>(this->options_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 476 | ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 477 | 3, |
| 478 | this->options(static_cast<int>(i)), |
| 479 | output); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 480 | } |
| 481 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 482 | // string version = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 483 | if (this->version().size() > 0) { |
| 484 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 485 | this->version().data(), static_cast<int>(this->version().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 486 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 487 | "google.protobuf.Api.version"); |
| 488 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 489 | 4, this->version(), output); |
| 490 | } |
| 491 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 492 | // .google.protobuf.SourceContext source_context = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 493 | if (this->has_source_context()) { |
| 494 | ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 495 | 5, this->_internal_source_context(), output); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 496 | } |
| 497 | |
| 498 | // repeated .google.protobuf.Mixin mixins = 6; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 499 | for (unsigned int i = 0, |
| 500 | n = static_cast<unsigned int>(this->mixins_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 501 | ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 502 | 6, |
| 503 | this->mixins(static_cast<int>(i)), |
| 504 | output); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 505 | } |
| 506 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 507 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 508 | if (this->syntax() != 0) { |
| 509 | ::google::protobuf::internal::WireFormatLite::WriteEnum( |
| 510 | 7, this->syntax(), output); |
| 511 | } |
| 512 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 513 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 514 | ::google::protobuf::internal::WireFormat::SerializeUnknownFields( |
| 515 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); |
| 516 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 517 | // @@protoc_insertion_point(serialize_end:google.protobuf.Api) |
| 518 | } |
| 519 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 520 | ::google::protobuf::uint8* Api::InternalSerializeWithCachedSizesToArray( |
| 521 | bool deterministic, ::google::protobuf::uint8* target) const { |
| 522 | (void)deterministic; // Unused |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 523 | // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Api) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 524 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 525 | (void) cached_has_bits; |
| 526 | |
| 527 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 528 | if (this->name().size() > 0) { |
| 529 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 530 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 531 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 532 | "google.protobuf.Api.name"); |
| 533 | target = |
| 534 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 535 | 1, this->name(), target); |
| 536 | } |
| 537 | |
| 538 | // repeated .google.protobuf.Method methods = 2; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 539 | for (unsigned int i = 0, |
| 540 | n = static_cast<unsigned int>(this->methods_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 541 | target = ::google::protobuf::internal::WireFormatLite:: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 542 | InternalWriteMessageToArray( |
| 543 | 2, this->methods(static_cast<int>(i)), deterministic, target); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 544 | } |
| 545 | |
| 546 | // repeated .google.protobuf.Option options = 3; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 547 | for (unsigned int i = 0, |
| 548 | n = static_cast<unsigned int>(this->options_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 549 | target = ::google::protobuf::internal::WireFormatLite:: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 550 | InternalWriteMessageToArray( |
| 551 | 3, this->options(static_cast<int>(i)), deterministic, target); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 552 | } |
| 553 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 554 | // string version = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 555 | if (this->version().size() > 0) { |
| 556 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 557 | this->version().data(), static_cast<int>(this->version().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 558 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 559 | "google.protobuf.Api.version"); |
| 560 | target = |
| 561 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 562 | 4, this->version(), target); |
| 563 | } |
| 564 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 565 | // .google.protobuf.SourceContext source_context = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 566 | if (this->has_source_context()) { |
| 567 | target = ::google::protobuf::internal::WireFormatLite:: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 568 | InternalWriteMessageToArray( |
| 569 | 5, this->_internal_source_context(), deterministic, target); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 570 | } |
| 571 | |
| 572 | // repeated .google.protobuf.Mixin mixins = 6; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 573 | for (unsigned int i = 0, |
| 574 | n = static_cast<unsigned int>(this->mixins_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 575 | target = ::google::protobuf::internal::WireFormatLite:: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 576 | InternalWriteMessageToArray( |
| 577 | 6, this->mixins(static_cast<int>(i)), deterministic, target); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 578 | } |
| 579 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 580 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 581 | if (this->syntax() != 0) { |
| 582 | target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( |
| 583 | 7, this->syntax(), target); |
| 584 | } |
| 585 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 586 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 587 | target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( |
| 588 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); |
| 589 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 590 | // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.Api) |
| 591 | return target; |
| 592 | } |
| 593 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 594 | size_t Api::ByteSizeLong() const { |
| 595 | // @@protoc_insertion_point(message_byte_size_start:google.protobuf.Api) |
| 596 | size_t total_size = 0; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 597 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 598 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 599 | total_size += |
| 600 | ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( |
| 601 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); |
| 602 | } |
| 603 | // repeated .google.protobuf.Method methods = 2; |
| 604 | { |
| 605 | unsigned int count = static_cast<unsigned int>(this->methods_size()); |
| 606 | total_size += 1UL * count; |
| 607 | for (unsigned int i = 0; i < count; i++) { |
| 608 | total_size += |
| 609 | ::google::protobuf::internal::WireFormatLite::MessageSize( |
| 610 | this->methods(static_cast<int>(i))); |
| 611 | } |
| 612 | } |
| 613 | |
| 614 | // repeated .google.protobuf.Option options = 3; |
| 615 | { |
| 616 | unsigned int count = static_cast<unsigned int>(this->options_size()); |
| 617 | total_size += 1UL * count; |
| 618 | for (unsigned int i = 0; i < count; i++) { |
| 619 | total_size += |
| 620 | ::google::protobuf::internal::WireFormatLite::MessageSize( |
| 621 | this->options(static_cast<int>(i))); |
| 622 | } |
| 623 | } |
| 624 | |
| 625 | // repeated .google.protobuf.Mixin mixins = 6; |
| 626 | { |
| 627 | unsigned int count = static_cast<unsigned int>(this->mixins_size()); |
| 628 | total_size += 1UL * count; |
| 629 | for (unsigned int i = 0; i < count; i++) { |
| 630 | total_size += |
| 631 | ::google::protobuf::internal::WireFormatLite::MessageSize( |
| 632 | this->mixins(static_cast<int>(i))); |
| 633 | } |
| 634 | } |
| 635 | |
| 636 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 637 | if (this->name().size() > 0) { |
| 638 | total_size += 1 + |
| 639 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 640 | this->name()); |
| 641 | } |
| 642 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 643 | // string version = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 644 | if (this->version().size() > 0) { |
| 645 | total_size += 1 + |
| 646 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 647 | this->version()); |
| 648 | } |
| 649 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 650 | // .google.protobuf.SourceContext source_context = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 651 | if (this->has_source_context()) { |
| 652 | total_size += 1 + |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 653 | ::google::protobuf::internal::WireFormatLite::MessageSize( |
| 654 | *source_context_); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 655 | } |
| 656 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 657 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 658 | if (this->syntax() != 0) { |
| 659 | total_size += 1 + |
| 660 | ::google::protobuf::internal::WireFormatLite::EnumSize(this->syntax()); |
| 661 | } |
| 662 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 663 | int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); |
| 664 | SetCachedSize(cached_size); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 665 | return total_size; |
| 666 | } |
| 667 | |
| 668 | void Api::MergeFrom(const ::google::protobuf::Message& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 669 | // @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Api) |
| 670 | GOOGLE_DCHECK_NE(&from, this); |
| 671 | const Api* source = |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 672 | ::google::protobuf::internal::DynamicCastToGenerated<const Api>( |
| 673 | &from); |
| 674 | if (source == NULL) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 675 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Api) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 676 | ::google::protobuf::internal::ReflectionOps::Merge(from, this); |
| 677 | } else { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 678 | // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Api) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 679 | MergeFrom(*source); |
| 680 | } |
| 681 | } |
| 682 | |
| 683 | void Api::MergeFrom(const Api& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 684 | // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Api) |
| 685 | GOOGLE_DCHECK_NE(&from, this); |
| 686 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
| 687 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 688 | (void) cached_has_bits; |
| 689 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 690 | methods_.MergeFrom(from.methods_); |
| 691 | options_.MergeFrom(from.options_); |
| 692 | mixins_.MergeFrom(from.mixins_); |
| 693 | if (from.name().size() > 0) { |
| 694 | |
| 695 | name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_); |
| 696 | } |
| 697 | if (from.version().size() > 0) { |
| 698 | |
| 699 | version_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.version_); |
| 700 | } |
| 701 | if (from.has_source_context()) { |
| 702 | mutable_source_context()->::google::protobuf::SourceContext::MergeFrom(from.source_context()); |
| 703 | } |
| 704 | if (from.syntax() != 0) { |
| 705 | set_syntax(from.syntax()); |
| 706 | } |
| 707 | } |
| 708 | |
| 709 | void Api::CopyFrom(const ::google::protobuf::Message& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 710 | // @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Api) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 711 | if (&from == this) return; |
| 712 | Clear(); |
| 713 | MergeFrom(from); |
| 714 | } |
| 715 | |
| 716 | void Api::CopyFrom(const Api& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 717 | // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Api) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 718 | if (&from == this) return; |
| 719 | Clear(); |
| 720 | MergeFrom(from); |
| 721 | } |
| 722 | |
| 723 | bool Api::IsInitialized() const { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 724 | return true; |
| 725 | } |
| 726 | |
| 727 | void Api::Swap(Api* other) { |
| 728 | if (other == this) return; |
| 729 | InternalSwap(other); |
| 730 | } |
| 731 | void Api::InternalSwap(Api* other) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 732 | using std::swap; |
| 733 | CastToBase(&methods_)->InternalSwap(CastToBase(&other->methods_)); |
| 734 | CastToBase(&options_)->InternalSwap(CastToBase(&other->options_)); |
| 735 | CastToBase(&mixins_)->InternalSwap(CastToBase(&other->mixins_)); |
| 736 | name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 737 | GetArenaNoVirtual()); |
| 738 | version_.Swap(&other->version_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 739 | GetArenaNoVirtual()); |
| 740 | swap(source_context_, other->source_context_); |
| 741 | swap(syntax_, other->syntax_); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 742 | _internal_metadata_.Swap(&other->_internal_metadata_); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 743 | } |
| 744 | |
| 745 | ::google::protobuf::Metadata Api::GetMetadata() const { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 746 | protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce(); |
| 747 | return ::protobuf_google_2fprotobuf_2fapi_2eproto::file_level_metadata[kIndexInFileMessages]; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 748 | } |
| 749 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 750 | |
| 751 | // =================================================================== |
| 752 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 753 | void Method::InitAsDefaultInstance() { |
| 754 | } |
| 755 | void Method::clear_options() { |
| 756 | options_.Clear(); |
| 757 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 758 | #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
| 759 | const int Method::kNameFieldNumber; |
| 760 | const int Method::kRequestTypeUrlFieldNumber; |
| 761 | const int Method::kRequestStreamingFieldNumber; |
| 762 | const int Method::kResponseTypeUrlFieldNumber; |
| 763 | const int Method::kResponseStreamingFieldNumber; |
| 764 | const int Method::kOptionsFieldNumber; |
| 765 | const int Method::kSyntaxFieldNumber; |
| 766 | #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
| 767 | |
| 768 | Method::Method() |
| 769 | : ::google::protobuf::Message(), _internal_metadata_(NULL) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 770 | ::google::protobuf::internal::InitSCC( |
| 771 | &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Method.base); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 772 | SharedCtor(); |
| 773 | // @@protoc_insertion_point(constructor:google.protobuf.Method) |
| 774 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 775 | Method::Method(const Method& from) |
| 776 | : ::google::protobuf::Message(), |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 777 | _internal_metadata_(NULL), |
| 778 | options_(from.options_) { |
| 779 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
| 780 | name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 781 | if (from.name().size() > 0) { |
| 782 | name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_); |
| 783 | } |
| 784 | request_type_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 785 | if (from.request_type_url().size() > 0) { |
| 786 | request_type_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.request_type_url_); |
| 787 | } |
| 788 | response_type_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 789 | if (from.response_type_url().size() > 0) { |
| 790 | response_type_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.response_type_url_); |
| 791 | } |
| 792 | ::memcpy(&request_streaming_, &from.request_streaming_, |
| 793 | static_cast<size_t>(reinterpret_cast<char*>(&syntax_) - |
| 794 | reinterpret_cast<char*>(&request_streaming_)) + sizeof(syntax_)); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 795 | // @@protoc_insertion_point(copy_constructor:google.protobuf.Method) |
| 796 | } |
| 797 | |
| 798 | void Method::SharedCtor() { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 799 | name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 800 | request_type_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 801 | response_type_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 802 | ::memset(&request_streaming_, 0, static_cast<size_t>( |
| 803 | reinterpret_cast<char*>(&syntax_) - |
| 804 | reinterpret_cast<char*>(&request_streaming_)) + sizeof(syntax_)); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 805 | } |
| 806 | |
| 807 | Method::~Method() { |
| 808 | // @@protoc_insertion_point(destructor:google.protobuf.Method) |
| 809 | SharedDtor(); |
| 810 | } |
| 811 | |
| 812 | void Method::SharedDtor() { |
| 813 | name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 814 | request_type_url_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 815 | response_type_url_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 816 | } |
| 817 | |
| 818 | void Method::SetCachedSize(int size) const { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 819 | _cached_size_.Set(size); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 820 | } |
| 821 | const ::google::protobuf::Descriptor* Method::descriptor() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 822 | ::protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce(); |
| 823 | return ::protobuf_google_2fprotobuf_2fapi_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 824 | } |
| 825 | |
| 826 | const Method& Method::default_instance() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 827 | ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Method.base); |
| 828 | return *internal_default_instance(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 829 | } |
| 830 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 831 | |
| 832 | void Method::Clear() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 833 | // @@protoc_insertion_point(message_clear_start:google.protobuf.Method) |
| 834 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 835 | // Prevent compiler warnings about cached_has_bits being unused |
| 836 | (void) cached_has_bits; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 837 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 838 | options_.Clear(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 839 | name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 840 | request_type_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 841 | response_type_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 842 | ::memset(&request_streaming_, 0, static_cast<size_t>( |
| 843 | reinterpret_cast<char*>(&syntax_) - |
| 844 | reinterpret_cast<char*>(&request_streaming_)) + sizeof(syntax_)); |
| 845 | _internal_metadata_.Clear(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 846 | } |
| 847 | |
| 848 | bool Method::MergePartialFromCodedStream( |
| 849 | ::google::protobuf::io::CodedInputStream* input) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 850 | #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 851 | ::google::protobuf::uint32 tag; |
| 852 | // @@protoc_insertion_point(parse_start:google.protobuf.Method) |
| 853 | for (;;) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 854 | ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 855 | tag = p.first; |
| 856 | if (!p.second) goto handle_unusual; |
| 857 | switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 858 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 859 | case 1: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 860 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 861 | static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 862 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 863 | input, this->mutable_name())); |
| 864 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 865 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 866 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 867 | "google.protobuf.Method.name")); |
| 868 | } else { |
| 869 | goto handle_unusual; |
| 870 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 871 | break; |
| 872 | } |
| 873 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 874 | // string request_type_url = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 875 | case 2: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 876 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 877 | static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 878 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 879 | input, this->mutable_request_type_url())); |
| 880 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 881 | this->request_type_url().data(), static_cast<int>(this->request_type_url().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 882 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 883 | "google.protobuf.Method.request_type_url")); |
| 884 | } else { |
| 885 | goto handle_unusual; |
| 886 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 887 | break; |
| 888 | } |
| 889 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 890 | // bool request_streaming = 3; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 891 | case 3: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 892 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 893 | static_cast< ::google::protobuf::uint8>(24u /* 24 & 0xFF */)) { |
| 894 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 895 | DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| 896 | bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( |
| 897 | input, &request_streaming_))); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 898 | } else { |
| 899 | goto handle_unusual; |
| 900 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 901 | break; |
| 902 | } |
| 903 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 904 | // string response_type_url = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 905 | case 4: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 906 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 907 | static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 908 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 909 | input, this->mutable_response_type_url())); |
| 910 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 911 | this->response_type_url().data(), static_cast<int>(this->response_type_url().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 912 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 913 | "google.protobuf.Method.response_type_url")); |
| 914 | } else { |
| 915 | goto handle_unusual; |
| 916 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 917 | break; |
| 918 | } |
| 919 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 920 | // bool response_streaming = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 921 | case 5: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 922 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 923 | static_cast< ::google::protobuf::uint8>(40u /* 40 & 0xFF */)) { |
| 924 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 925 | DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| 926 | bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( |
| 927 | input, &response_streaming_))); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 928 | } else { |
| 929 | goto handle_unusual; |
| 930 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 931 | break; |
| 932 | } |
| 933 | |
| 934 | // repeated .google.protobuf.Option options = 6; |
| 935 | case 6: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 936 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 937 | static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { |
| 938 | DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 939 | input, add_options())); |
| 940 | } else { |
| 941 | goto handle_unusual; |
| 942 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 943 | break; |
| 944 | } |
| 945 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 946 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 947 | case 7: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 948 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 949 | static_cast< ::google::protobuf::uint8>(56u /* 56 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 950 | int value; |
| 951 | DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< |
| 952 | int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( |
| 953 | input, &value))); |
| 954 | set_syntax(static_cast< ::google::protobuf::Syntax >(value)); |
| 955 | } else { |
| 956 | goto handle_unusual; |
| 957 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 958 | break; |
| 959 | } |
| 960 | |
| 961 | default: { |
| 962 | handle_unusual: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 963 | if (tag == 0) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 964 | goto success; |
| 965 | } |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 966 | DO_(::google::protobuf::internal::WireFormat::SkipField( |
| 967 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 968 | break; |
| 969 | } |
| 970 | } |
| 971 | } |
| 972 | success: |
| 973 | // @@protoc_insertion_point(parse_success:google.protobuf.Method) |
| 974 | return true; |
| 975 | failure: |
| 976 | // @@protoc_insertion_point(parse_failure:google.protobuf.Method) |
| 977 | return false; |
| 978 | #undef DO_ |
| 979 | } |
| 980 | |
| 981 | void Method::SerializeWithCachedSizes( |
| 982 | ::google::protobuf::io::CodedOutputStream* output) const { |
| 983 | // @@protoc_insertion_point(serialize_start:google.protobuf.Method) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 984 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 985 | (void) cached_has_bits; |
| 986 | |
| 987 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 988 | if (this->name().size() > 0) { |
| 989 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 990 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 991 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 992 | "google.protobuf.Method.name"); |
| 993 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 994 | 1, this->name(), output); |
| 995 | } |
| 996 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 997 | // string request_type_url = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 998 | if (this->request_type_url().size() > 0) { |
| 999 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1000 | this->request_type_url().data(), static_cast<int>(this->request_type_url().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1001 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1002 | "google.protobuf.Method.request_type_url"); |
| 1003 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 1004 | 2, this->request_type_url(), output); |
| 1005 | } |
| 1006 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1007 | // bool request_streaming = 3; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1008 | if (this->request_streaming() != 0) { |
| 1009 | ::google::protobuf::internal::WireFormatLite::WriteBool(3, this->request_streaming(), output); |
| 1010 | } |
| 1011 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1012 | // string response_type_url = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1013 | if (this->response_type_url().size() > 0) { |
| 1014 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1015 | this->response_type_url().data(), static_cast<int>(this->response_type_url().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1016 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1017 | "google.protobuf.Method.response_type_url"); |
| 1018 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 1019 | 4, this->response_type_url(), output); |
| 1020 | } |
| 1021 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1022 | // bool response_streaming = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1023 | if (this->response_streaming() != 0) { |
| 1024 | ::google::protobuf::internal::WireFormatLite::WriteBool(5, this->response_streaming(), output); |
| 1025 | } |
| 1026 | |
| 1027 | // repeated .google.protobuf.Option options = 6; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1028 | for (unsigned int i = 0, |
| 1029 | n = static_cast<unsigned int>(this->options_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1030 | ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1031 | 6, |
| 1032 | this->options(static_cast<int>(i)), |
| 1033 | output); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1034 | } |
| 1035 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1036 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1037 | if (this->syntax() != 0) { |
| 1038 | ::google::protobuf::internal::WireFormatLite::WriteEnum( |
| 1039 | 7, this->syntax(), output); |
| 1040 | } |
| 1041 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1042 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 1043 | ::google::protobuf::internal::WireFormat::SerializeUnknownFields( |
| 1044 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); |
| 1045 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1046 | // @@protoc_insertion_point(serialize_end:google.protobuf.Method) |
| 1047 | } |
| 1048 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1049 | ::google::protobuf::uint8* Method::InternalSerializeWithCachedSizesToArray( |
| 1050 | bool deterministic, ::google::protobuf::uint8* target) const { |
| 1051 | (void)deterministic; // Unused |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1052 | // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Method) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1053 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 1054 | (void) cached_has_bits; |
| 1055 | |
| 1056 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1057 | if (this->name().size() > 0) { |
| 1058 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1059 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1060 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1061 | "google.protobuf.Method.name"); |
| 1062 | target = |
| 1063 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 1064 | 1, this->name(), target); |
| 1065 | } |
| 1066 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1067 | // string request_type_url = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1068 | if (this->request_type_url().size() > 0) { |
| 1069 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1070 | this->request_type_url().data(), static_cast<int>(this->request_type_url().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1071 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1072 | "google.protobuf.Method.request_type_url"); |
| 1073 | target = |
| 1074 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 1075 | 2, this->request_type_url(), target); |
| 1076 | } |
| 1077 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1078 | // bool request_streaming = 3; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1079 | if (this->request_streaming() != 0) { |
| 1080 | target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(3, this->request_streaming(), target); |
| 1081 | } |
| 1082 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1083 | // string response_type_url = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1084 | if (this->response_type_url().size() > 0) { |
| 1085 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1086 | this->response_type_url().data(), static_cast<int>(this->response_type_url().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1087 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1088 | "google.protobuf.Method.response_type_url"); |
| 1089 | target = |
| 1090 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 1091 | 4, this->response_type_url(), target); |
| 1092 | } |
| 1093 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1094 | // bool response_streaming = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1095 | if (this->response_streaming() != 0) { |
| 1096 | target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(5, this->response_streaming(), target); |
| 1097 | } |
| 1098 | |
| 1099 | // repeated .google.protobuf.Option options = 6; |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1100 | for (unsigned int i = 0, |
| 1101 | n = static_cast<unsigned int>(this->options_size()); i < n; i++) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1102 | target = ::google::protobuf::internal::WireFormatLite:: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1103 | InternalWriteMessageToArray( |
| 1104 | 6, this->options(static_cast<int>(i)), deterministic, target); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1105 | } |
| 1106 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1107 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1108 | if (this->syntax() != 0) { |
| 1109 | target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( |
| 1110 | 7, this->syntax(), target); |
| 1111 | } |
| 1112 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1113 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 1114 | target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( |
| 1115 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); |
| 1116 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1117 | // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.Method) |
| 1118 | return target; |
| 1119 | } |
| 1120 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1121 | size_t Method::ByteSizeLong() const { |
| 1122 | // @@protoc_insertion_point(message_byte_size_start:google.protobuf.Method) |
| 1123 | size_t total_size = 0; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1124 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1125 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 1126 | total_size += |
| 1127 | ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( |
| 1128 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); |
| 1129 | } |
| 1130 | // repeated .google.protobuf.Option options = 6; |
| 1131 | { |
| 1132 | unsigned int count = static_cast<unsigned int>(this->options_size()); |
| 1133 | total_size += 1UL * count; |
| 1134 | for (unsigned int i = 0; i < count; i++) { |
| 1135 | total_size += |
| 1136 | ::google::protobuf::internal::WireFormatLite::MessageSize( |
| 1137 | this->options(static_cast<int>(i))); |
| 1138 | } |
| 1139 | } |
| 1140 | |
| 1141 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1142 | if (this->name().size() > 0) { |
| 1143 | total_size += 1 + |
| 1144 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 1145 | this->name()); |
| 1146 | } |
| 1147 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1148 | // string request_type_url = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1149 | if (this->request_type_url().size() > 0) { |
| 1150 | total_size += 1 + |
| 1151 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 1152 | this->request_type_url()); |
| 1153 | } |
| 1154 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1155 | // string response_type_url = 4; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1156 | if (this->response_type_url().size() > 0) { |
| 1157 | total_size += 1 + |
| 1158 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 1159 | this->response_type_url()); |
| 1160 | } |
| 1161 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1162 | // bool request_streaming = 3; |
| 1163 | if (this->request_streaming() != 0) { |
| 1164 | total_size += 1 + 1; |
| 1165 | } |
| 1166 | |
| 1167 | // bool response_streaming = 5; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1168 | if (this->response_streaming() != 0) { |
| 1169 | total_size += 1 + 1; |
| 1170 | } |
| 1171 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1172 | // .google.protobuf.Syntax syntax = 7; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1173 | if (this->syntax() != 0) { |
| 1174 | total_size += 1 + |
| 1175 | ::google::protobuf::internal::WireFormatLite::EnumSize(this->syntax()); |
| 1176 | } |
| 1177 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1178 | int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); |
| 1179 | SetCachedSize(cached_size); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1180 | return total_size; |
| 1181 | } |
| 1182 | |
| 1183 | void Method::MergeFrom(const ::google::protobuf::Message& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1184 | // @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Method) |
| 1185 | GOOGLE_DCHECK_NE(&from, this); |
| 1186 | const Method* source = |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1187 | ::google::protobuf::internal::DynamicCastToGenerated<const Method>( |
| 1188 | &from); |
| 1189 | if (source == NULL) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1190 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Method) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1191 | ::google::protobuf::internal::ReflectionOps::Merge(from, this); |
| 1192 | } else { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1193 | // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Method) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1194 | MergeFrom(*source); |
| 1195 | } |
| 1196 | } |
| 1197 | |
| 1198 | void Method::MergeFrom(const Method& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1199 | // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Method) |
| 1200 | GOOGLE_DCHECK_NE(&from, this); |
| 1201 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
| 1202 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 1203 | (void) cached_has_bits; |
| 1204 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1205 | options_.MergeFrom(from.options_); |
| 1206 | if (from.name().size() > 0) { |
| 1207 | |
| 1208 | name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_); |
| 1209 | } |
| 1210 | if (from.request_type_url().size() > 0) { |
| 1211 | |
| 1212 | request_type_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.request_type_url_); |
| 1213 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1214 | if (from.response_type_url().size() > 0) { |
| 1215 | |
| 1216 | response_type_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.response_type_url_); |
| 1217 | } |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1218 | if (from.request_streaming() != 0) { |
| 1219 | set_request_streaming(from.request_streaming()); |
| 1220 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1221 | if (from.response_streaming() != 0) { |
| 1222 | set_response_streaming(from.response_streaming()); |
| 1223 | } |
| 1224 | if (from.syntax() != 0) { |
| 1225 | set_syntax(from.syntax()); |
| 1226 | } |
| 1227 | } |
| 1228 | |
| 1229 | void Method::CopyFrom(const ::google::protobuf::Message& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1230 | // @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Method) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1231 | if (&from == this) return; |
| 1232 | Clear(); |
| 1233 | MergeFrom(from); |
| 1234 | } |
| 1235 | |
| 1236 | void Method::CopyFrom(const Method& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1237 | // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Method) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1238 | if (&from == this) return; |
| 1239 | Clear(); |
| 1240 | MergeFrom(from); |
| 1241 | } |
| 1242 | |
| 1243 | bool Method::IsInitialized() const { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1244 | return true; |
| 1245 | } |
| 1246 | |
| 1247 | void Method::Swap(Method* other) { |
| 1248 | if (other == this) return; |
| 1249 | InternalSwap(other); |
| 1250 | } |
| 1251 | void Method::InternalSwap(Method* other) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1252 | using std::swap; |
| 1253 | CastToBase(&options_)->InternalSwap(CastToBase(&other->options_)); |
| 1254 | name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 1255 | GetArenaNoVirtual()); |
| 1256 | request_type_url_.Swap(&other->request_type_url_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 1257 | GetArenaNoVirtual()); |
| 1258 | response_type_url_.Swap(&other->response_type_url_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 1259 | GetArenaNoVirtual()); |
| 1260 | swap(request_streaming_, other->request_streaming_); |
| 1261 | swap(response_streaming_, other->response_streaming_); |
| 1262 | swap(syntax_, other->syntax_); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1263 | _internal_metadata_.Swap(&other->_internal_metadata_); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1264 | } |
| 1265 | |
| 1266 | ::google::protobuf::Metadata Method::GetMetadata() const { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1267 | protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce(); |
| 1268 | return ::protobuf_google_2fprotobuf_2fapi_2eproto::file_level_metadata[kIndexInFileMessages]; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1269 | } |
| 1270 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1271 | |
| 1272 | // =================================================================== |
| 1273 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1274 | void Mixin::InitAsDefaultInstance() { |
| 1275 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1276 | #if !defined(_MSC_VER) || _MSC_VER >= 1900 |
| 1277 | const int Mixin::kNameFieldNumber; |
| 1278 | const int Mixin::kRootFieldNumber; |
| 1279 | #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 |
| 1280 | |
| 1281 | Mixin::Mixin() |
| 1282 | : ::google::protobuf::Message(), _internal_metadata_(NULL) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1283 | ::google::protobuf::internal::InitSCC( |
| 1284 | &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Mixin.base); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1285 | SharedCtor(); |
| 1286 | // @@protoc_insertion_point(constructor:google.protobuf.Mixin) |
| 1287 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1288 | Mixin::Mixin(const Mixin& from) |
| 1289 | : ::google::protobuf::Message(), |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1290 | _internal_metadata_(NULL) { |
| 1291 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
| 1292 | name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 1293 | if (from.name().size() > 0) { |
| 1294 | name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_); |
| 1295 | } |
| 1296 | root_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 1297 | if (from.root().size() > 0) { |
| 1298 | root_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.root_); |
| 1299 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1300 | // @@protoc_insertion_point(copy_constructor:google.protobuf.Mixin) |
| 1301 | } |
| 1302 | |
| 1303 | void Mixin::SharedCtor() { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1304 | name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 1305 | root_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 1306 | } |
| 1307 | |
| 1308 | Mixin::~Mixin() { |
| 1309 | // @@protoc_insertion_point(destructor:google.protobuf.Mixin) |
| 1310 | SharedDtor(); |
| 1311 | } |
| 1312 | |
| 1313 | void Mixin::SharedDtor() { |
| 1314 | name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 1315 | root_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1316 | } |
| 1317 | |
| 1318 | void Mixin::SetCachedSize(int size) const { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1319 | _cached_size_.Set(size); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1320 | } |
| 1321 | const ::google::protobuf::Descriptor* Mixin::descriptor() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1322 | ::protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce(); |
| 1323 | return ::protobuf_google_2fprotobuf_2fapi_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1324 | } |
| 1325 | |
| 1326 | const Mixin& Mixin::default_instance() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1327 | ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Mixin.base); |
| 1328 | return *internal_default_instance(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1329 | } |
| 1330 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1331 | |
| 1332 | void Mixin::Clear() { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1333 | // @@protoc_insertion_point(message_clear_start:google.protobuf.Mixin) |
| 1334 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 1335 | // Prevent compiler warnings about cached_has_bits being unused |
| 1336 | (void) cached_has_bits; |
| 1337 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1338 | name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
| 1339 | root_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1340 | _internal_metadata_.Clear(); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1341 | } |
| 1342 | |
| 1343 | bool Mixin::MergePartialFromCodedStream( |
| 1344 | ::google::protobuf::io::CodedInputStream* input) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1345 | #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1346 | ::google::protobuf::uint32 tag; |
| 1347 | // @@protoc_insertion_point(parse_start:google.protobuf.Mixin) |
| 1348 | for (;;) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1349 | ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1350 | tag = p.first; |
| 1351 | if (!p.second) goto handle_unusual; |
| 1352 | switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1353 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1354 | case 1: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1355 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 1356 | static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1357 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 1358 | input, this->mutable_name())); |
| 1359 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1360 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1361 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 1362 | "google.protobuf.Mixin.name")); |
| 1363 | } else { |
| 1364 | goto handle_unusual; |
| 1365 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1366 | break; |
| 1367 | } |
| 1368 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1369 | // string root = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1370 | case 2: { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1371 | if (static_cast< ::google::protobuf::uint8>(tag) == |
| 1372 | static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1373 | DO_(::google::protobuf::internal::WireFormatLite::ReadString( |
| 1374 | input, this->mutable_root())); |
| 1375 | DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1376 | this->root().data(), static_cast<int>(this->root().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1377 | ::google::protobuf::internal::WireFormatLite::PARSE, |
| 1378 | "google.protobuf.Mixin.root")); |
| 1379 | } else { |
| 1380 | goto handle_unusual; |
| 1381 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1382 | break; |
| 1383 | } |
| 1384 | |
| 1385 | default: { |
| 1386 | handle_unusual: |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1387 | if (tag == 0) { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1388 | goto success; |
| 1389 | } |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1390 | DO_(::google::protobuf::internal::WireFormat::SkipField( |
| 1391 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1392 | break; |
| 1393 | } |
| 1394 | } |
| 1395 | } |
| 1396 | success: |
| 1397 | // @@protoc_insertion_point(parse_success:google.protobuf.Mixin) |
| 1398 | return true; |
| 1399 | failure: |
| 1400 | // @@protoc_insertion_point(parse_failure:google.protobuf.Mixin) |
| 1401 | return false; |
| 1402 | #undef DO_ |
| 1403 | } |
| 1404 | |
| 1405 | void Mixin::SerializeWithCachedSizes( |
| 1406 | ::google::protobuf::io::CodedOutputStream* output) const { |
| 1407 | // @@protoc_insertion_point(serialize_start:google.protobuf.Mixin) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1408 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 1409 | (void) cached_has_bits; |
| 1410 | |
| 1411 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1412 | if (this->name().size() > 0) { |
| 1413 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1414 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1415 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1416 | "google.protobuf.Mixin.name"); |
| 1417 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 1418 | 1, this->name(), output); |
| 1419 | } |
| 1420 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1421 | // string root = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1422 | if (this->root().size() > 0) { |
| 1423 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1424 | this->root().data(), static_cast<int>(this->root().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1425 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1426 | "google.protobuf.Mixin.root"); |
| 1427 | ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( |
| 1428 | 2, this->root(), output); |
| 1429 | } |
| 1430 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1431 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 1432 | ::google::protobuf::internal::WireFormat::SerializeUnknownFields( |
| 1433 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); |
| 1434 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1435 | // @@protoc_insertion_point(serialize_end:google.protobuf.Mixin) |
| 1436 | } |
| 1437 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1438 | ::google::protobuf::uint8* Mixin::InternalSerializeWithCachedSizesToArray( |
| 1439 | bool deterministic, ::google::protobuf::uint8* target) const { |
| 1440 | (void)deterministic; // Unused |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1441 | // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Mixin) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1442 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 1443 | (void) cached_has_bits; |
| 1444 | |
| 1445 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1446 | if (this->name().size() > 0) { |
| 1447 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1448 | this->name().data(), static_cast<int>(this->name().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1449 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1450 | "google.protobuf.Mixin.name"); |
| 1451 | target = |
| 1452 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 1453 | 1, this->name(), target); |
| 1454 | } |
| 1455 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1456 | // string root = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1457 | if (this->root().size() > 0) { |
| 1458 | ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1459 | this->root().data(), static_cast<int>(this->root().length()), |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1460 | ::google::protobuf::internal::WireFormatLite::SERIALIZE, |
| 1461 | "google.protobuf.Mixin.root"); |
| 1462 | target = |
| 1463 | ::google::protobuf::internal::WireFormatLite::WriteStringToArray( |
| 1464 | 2, this->root(), target); |
| 1465 | } |
| 1466 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1467 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 1468 | target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( |
| 1469 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); |
| 1470 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1471 | // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.Mixin) |
| 1472 | return target; |
| 1473 | } |
| 1474 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1475 | size_t Mixin::ByteSizeLong() const { |
| 1476 | // @@protoc_insertion_point(message_byte_size_start:google.protobuf.Mixin) |
| 1477 | size_t total_size = 0; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1478 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1479 | if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { |
| 1480 | total_size += |
| 1481 | ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( |
| 1482 | (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); |
| 1483 | } |
| 1484 | // string name = 1; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1485 | if (this->name().size() > 0) { |
| 1486 | total_size += 1 + |
| 1487 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 1488 | this->name()); |
| 1489 | } |
| 1490 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1491 | // string root = 2; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1492 | if (this->root().size() > 0) { |
| 1493 | total_size += 1 + |
| 1494 | ::google::protobuf::internal::WireFormatLite::StringSize( |
| 1495 | this->root()); |
| 1496 | } |
| 1497 | |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1498 | int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); |
| 1499 | SetCachedSize(cached_size); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1500 | return total_size; |
| 1501 | } |
| 1502 | |
| 1503 | void Mixin::MergeFrom(const ::google::protobuf::Message& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1504 | // @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Mixin) |
| 1505 | GOOGLE_DCHECK_NE(&from, this); |
| 1506 | const Mixin* source = |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1507 | ::google::protobuf::internal::DynamicCastToGenerated<const Mixin>( |
| 1508 | &from); |
| 1509 | if (source == NULL) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1510 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Mixin) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1511 | ::google::protobuf::internal::ReflectionOps::Merge(from, this); |
| 1512 | } else { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1513 | // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Mixin) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1514 | MergeFrom(*source); |
| 1515 | } |
| 1516 | } |
| 1517 | |
| 1518 | void Mixin::MergeFrom(const Mixin& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1519 | // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Mixin) |
| 1520 | GOOGLE_DCHECK_NE(&from, this); |
| 1521 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
| 1522 | ::google::protobuf::uint32 cached_has_bits = 0; |
| 1523 | (void) cached_has_bits; |
| 1524 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1525 | if (from.name().size() > 0) { |
| 1526 | |
| 1527 | name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_); |
| 1528 | } |
| 1529 | if (from.root().size() > 0) { |
| 1530 | |
| 1531 | root_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.root_); |
| 1532 | } |
| 1533 | } |
| 1534 | |
| 1535 | void Mixin::CopyFrom(const ::google::protobuf::Message& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1536 | // @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Mixin) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1537 | if (&from == this) return; |
| 1538 | Clear(); |
| 1539 | MergeFrom(from); |
| 1540 | } |
| 1541 | |
| 1542 | void Mixin::CopyFrom(const Mixin& from) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1543 | // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Mixin) |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1544 | if (&from == this) return; |
| 1545 | Clear(); |
| 1546 | MergeFrom(from); |
| 1547 | } |
| 1548 | |
| 1549 | bool Mixin::IsInitialized() const { |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1550 | return true; |
| 1551 | } |
| 1552 | |
| 1553 | void Mixin::Swap(Mixin* other) { |
| 1554 | if (other == this) return; |
| 1555 | InternalSwap(other); |
| 1556 | } |
| 1557 | void Mixin::InternalSwap(Mixin* other) { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1558 | using std::swap; |
| 1559 | name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 1560 | GetArenaNoVirtual()); |
| 1561 | root_.Swap(&other->root_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), |
| 1562 | GetArenaNoVirtual()); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1563 | _internal_metadata_.Swap(&other->_internal_metadata_); |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1564 | } |
| 1565 | |
| 1566 | ::google::protobuf::Metadata Mixin::GetMetadata() const { |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1567 | protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce(); |
| 1568 | return ::protobuf_google_2fprotobuf_2fapi_2eproto::file_level_metadata[kIndexInFileMessages]; |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1569 | } |
| 1570 | |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1571 | |
| 1572 | // @@protoc_insertion_point(namespace_scope) |
Austin Schuh | 40c1652 | 2018-10-28 20:27:54 -0700 | [diff] [blame^] | 1573 | } // namespace protobuf |
| 1574 | } // namespace google |
| 1575 | namespace google { |
| 1576 | namespace protobuf { |
| 1577 | template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::Api* Arena::CreateMaybeMessage< ::google::protobuf::Api >(Arena* arena) { |
| 1578 | return Arena::CreateInternal< ::google::protobuf::Api >(arena); |
| 1579 | } |
| 1580 | template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::Method* Arena::CreateMaybeMessage< ::google::protobuf::Method >(Arena* arena) { |
| 1581 | return Arena::CreateInternal< ::google::protobuf::Method >(arena); |
| 1582 | } |
| 1583 | template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::Mixin* Arena::CreateMaybeMessage< ::google::protobuf::Mixin >(Arena* arena) { |
| 1584 | return Arena::CreateInternal< ::google::protobuf::Mixin >(arena); |
| 1585 | } |
Brian Silverman | 9c614bc | 2016-02-15 20:20:02 -0500 | [diff] [blame] | 1586 | } // namespace protobuf |
| 1587 | } // namespace google |
| 1588 | |
| 1589 | // @@protoc_insertion_point(global_scope) |