aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/google/protobuf/api.pb.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/google/protobuf/api.pb.cc')
-rw-r--r--src/google/protobuf/api.pb.cc249
1 files changed, 115 insertions, 134 deletions
diff --git a/src/google/protobuf/api.pb.cc b/src/google/protobuf/api.pb.cc
index 439a47c6..273307c7 100644
--- a/src/google/protobuf/api.pb.cc
+++ b/src/google/protobuf/api.pb.cc
@@ -7,7 +7,6 @@
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
-#include <google/protobuf/stubs/once.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
@@ -19,6 +18,17 @@
#include "third_party/protobuf/version.h"
#endif
// @@protoc_insertion_point(includes)
+
+namespace protobuf_google_2fprotobuf_2fapi_2eproto {
+extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fapi_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Mixin;
+extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fapi_2eproto ::google::protobuf::internal::SCCInfo<1> scc_info_Method;
+} // namespace protobuf_google_2fprotobuf_2fapi_2eproto
+namespace protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto {
+extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_SourceContext;
+} // namespace protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto
+namespace protobuf_google_2fprotobuf_2ftype_2eproto {
+extern PROTOBUF_INTERNAL_EXPORT_protobuf_google_2fprotobuf_2ftype_2eproto ::google::protobuf::internal::SCCInfo<1> scc_info_Option;
+} // namespace protobuf_google_2fprotobuf_2ftype_2eproto
namespace google {
namespace protobuf {
class ApiDefaultTypeInternal {
@@ -39,18 +49,9 @@ class MixinDefaultTypeInternal {
} // namespace protobuf
} // namespace google
namespace protobuf_google_2fprotobuf_2fapi_2eproto {
-void InitDefaultsApiImpl() {
+static void InitDefaultsApi() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
-#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
- ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
-#else
- ::google::protobuf::internal::InitProtobufDefaults();
-#endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
- protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsMethod();
- protobuf_google_2fprotobuf_2ftype_2eproto::InitDefaultsOption();
- protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto::InitDefaultsSourceContext();
- protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsMixin();
{
void* ptr = &::google::protobuf::_Api_default_instance_;
new (ptr) ::google::protobuf::Api();
@@ -59,20 +60,16 @@ void InitDefaultsApiImpl() {
::google::protobuf::Api::InitAsDefaultInstance();
}
-void InitDefaultsApi() {
- static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
- ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsApiImpl);
-}
+LIBPROTOBUF_EXPORT ::google::protobuf::internal::SCCInfo<4> scc_info_Api =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 4, InitDefaultsApi}, {
+ &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Method.base,
+ &protobuf_google_2fprotobuf_2ftype_2eproto::scc_info_Option.base,
+ &protobuf_google_2fprotobuf_2fsource_5fcontext_2eproto::scc_info_SourceContext.base,
+ &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Mixin.base,}};
-void InitDefaultsMethodImpl() {
+static void InitDefaultsMethod() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
-#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
- ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
-#else
- ::google::protobuf::internal::InitProtobufDefaults();
-#endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
- protobuf_google_2fprotobuf_2ftype_2eproto::InitDefaultsOption();
{
void* ptr = &::google::protobuf::_Method_default_instance_;
new (ptr) ::google::protobuf::Method();
@@ -81,19 +78,13 @@ void InitDefaultsMethodImpl() {
::google::protobuf::Method::InitAsDefaultInstance();
}
-void InitDefaultsMethod() {
- static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
- ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsMethodImpl);
-}
+LIBPROTOBUF_EXPORT ::google::protobuf::internal::SCCInfo<1> scc_info_Method =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsMethod}, {
+ &protobuf_google_2fprotobuf_2ftype_2eproto::scc_info_Option.base,}};
-void InitDefaultsMixinImpl() {
+static void InitDefaultsMixin() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
-#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
- ::google::protobuf::internal::InitProtobufDefaultsForceUnique();
-#else
- ::google::protobuf::internal::InitProtobufDefaults();
-#endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
{
void* ptr = &::google::protobuf::_Mixin_default_instance_;
new (ptr) ::google::protobuf::Mixin();
@@ -102,9 +93,13 @@ void InitDefaultsMixinImpl() {
::google::protobuf::Mixin::InitAsDefaultInstance();
}
-void InitDefaultsMixin() {
- static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
- ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsMixinImpl);
+LIBPROTOBUF_EXPORT ::google::protobuf::internal::SCCInfo<0> scc_info_Mixin =
+ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsMixin}, {}};
+
+void InitDefaults() {
+ ::google::protobuf::internal::InitSCC(&scc_info_Api.base);
+ ::google::protobuf::internal::InitSCC(&scc_info_Method.base);
+ ::google::protobuf::internal::InitSCC(&scc_info_Mixin.base);
}
::google::protobuf::Metadata file_level_metadata[3];
@@ -154,17 +149,16 @@ static ::google::protobuf::Message const * const file_default_instances[] = {
reinterpret_cast<const ::google::protobuf::Message*>(&::google::protobuf::_Mixin_default_instance_),
};
-void protobuf_AssignDescriptors() {
+static void protobuf_AssignDescriptors() {
AddDescriptors();
- ::google::protobuf::MessageFactory* factory = NULL;
AssignDescriptors(
- "google/protobuf/api.proto", schemas, file_default_instances, TableStruct::offsets, factory,
+ "google/protobuf/api.proto", schemas, file_default_instances, TableStruct::offsets,
file_level_metadata, NULL, NULL);
}
-void protobuf_AssignDescriptorsOnce() {
- static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
- ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors);
+static void protobuf_AssignDescriptorsOnce() {
+ static ::google::protobuf::internal::once_flag once;
+ ::google::protobuf::internal::call_once(once, protobuf_AssignDescriptors);
}
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD;
@@ -173,7 +167,7 @@ void protobuf_RegisterTypes(const ::std::string&) {
::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 3);
}
-void AddDescriptorsImpl() {
+static void AddDescriptorsImpl() {
InitDefaults();
static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
"\n\031google/protobuf/api.proto\022\017google.prot"
@@ -205,8 +199,8 @@ void AddDescriptorsImpl() {
}
void AddDescriptors() {
- static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
- ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
+ static ::google::protobuf::internal::once_flag once;
+ ::google::protobuf::internal::call_once(once, AddDescriptorsImpl);
}
// Force AddDescriptors() to be called at dynamic initialization time.
struct StaticDescriptorInitializer {
@@ -245,9 +239,8 @@ const int Api::kSyntaxFieldNumber;
Api::Api()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
- if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
- ::protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsApi();
- }
+ ::google::protobuf::internal::InitSCC(
+ &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Api.base);
SharedCtor();
// @@protoc_insertion_point(constructor:google.protobuf.Api)
}
@@ -256,8 +249,7 @@ Api::Api(const Api& from)
_internal_metadata_(NULL),
methods_(from.methods_),
options_(from.options_),
- mixins_(from.mixins_),
- _cached_size_(0) {
+ mixins_(from.mixins_) {
_internal_metadata_.MergeFrom(from._internal_metadata_);
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.name().size() > 0) {
@@ -282,7 +274,6 @@ void Api::SharedCtor() {
::memset(&source_context_, 0, static_cast<size_t>(
reinterpret_cast<char*>(&syntax_) -
reinterpret_cast<char*>(&source_context_)) + sizeof(syntax_));
- _cached_size_ = 0;
}
Api::~Api() {
@@ -297,9 +288,7 @@ void Api::SharedDtor() {
}
void Api::SetCachedSize(int size) const {
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
+ _cached_size_.Set(size);
}
const ::google::protobuf::Descriptor* Api::descriptor() {
::protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce();
@@ -307,17 +296,10 @@ const ::google::protobuf::Descriptor* Api::descriptor() {
}
const Api& Api::default_instance() {
- ::protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsApi();
+ ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Api.base);
return *internal_default_instance();
}
-Api* Api::New(::google::protobuf::Arena* arena) const {
- Api* n = new Api;
- if (arena != NULL) {
- arena->Own(n);
- }
- return n;
-}
void Api::Clear() {
// @@protoc_insertion_point(message_clear_start:google.protobuf.Api)
@@ -344,7 +326,7 @@ bool Api::MergePartialFromCodedStream(
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:google.protobuf.Api)
for (;;) {
- ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -368,7 +350,8 @@ bool Api::MergePartialFromCodedStream(
case 2: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_methods()));
+ DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
+ input, add_methods()));
} else {
goto handle_unusual;
}
@@ -379,7 +362,8 @@ bool Api::MergePartialFromCodedStream(
case 3: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_options()));
+ DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
+ input, add_options()));
} else {
goto handle_unusual;
}
@@ -418,7 +402,8 @@ bool Api::MergePartialFromCodedStream(
case 6: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_mixins()));
+ DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
+ input, add_mixins()));
} else {
goto handle_unusual;
}
@@ -429,7 +414,7 @@ bool Api::MergePartialFromCodedStream(
case 7: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(56u /* 56 & 0xFF */)) {
- int value;
+ int value = 0;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
@@ -480,14 +465,18 @@ void Api::SerializeWithCachedSizes(
for (unsigned int i = 0,
n = static_cast<unsigned int>(this->methods_size()); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 2, this->methods(static_cast<int>(i)), output);
+ 2,
+ this->methods(static_cast<int>(i)),
+ output);
}
// repeated .google.protobuf.Option options = 3;
for (unsigned int i = 0,
n = static_cast<unsigned int>(this->options_size()); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 3, this->options(static_cast<int>(i)), output);
+ 3,
+ this->options(static_cast<int>(i)),
+ output);
}
// string version = 4;
@@ -503,14 +492,16 @@ void Api::SerializeWithCachedSizes(
// .google.protobuf.SourceContext source_context = 5;
if (this->has_source_context()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 5, *this->source_context_, output);
+ 5, this->_internal_source_context(), output);
}
// repeated .google.protobuf.Mixin mixins = 6;
for (unsigned int i = 0,
n = static_cast<unsigned int>(this->mixins_size()); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 6, this->mixins(static_cast<int>(i)), output);
+ 6,
+ this->mixins(static_cast<int>(i)),
+ output);
}
// .google.protobuf.Syntax syntax = 7;
@@ -575,7 +566,7 @@ void Api::SerializeWithCachedSizes(
if (this->has_source_context()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageToArray(
- 5, *this->source_context_, deterministic, target);
+ 5, this->_internal_source_context(), deterministic, target);
}
// repeated .google.protobuf.Mixin mixins = 6;
@@ -660,7 +651,7 @@ size_t Api::ByteSizeLong() const {
if (this->has_source_context()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSize(
- *this->source_context_);
+ *source_context_);
}
// .google.protobuf.Syntax syntax = 7;
@@ -670,9 +661,7 @@ size_t Api::ByteSizeLong() const {
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = cached_size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
+ SetCachedSize(cached_size);
return total_size;
}
@@ -741,15 +730,16 @@ void Api::Swap(Api* other) {
}
void Api::InternalSwap(Api* other) {
using std::swap;
- methods_.InternalSwap(&other->methods_);
- options_.InternalSwap(&other->options_);
- mixins_.InternalSwap(&other->mixins_);
- name_.Swap(&other->name_);
- version_.Swap(&other->version_);
+ CastToBase(&methods_)->InternalSwap(CastToBase(&other->methods_));
+ CastToBase(&options_)->InternalSwap(CastToBase(&other->options_));
+ CastToBase(&mixins_)->InternalSwap(CastToBase(&other->mixins_));
+ name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ version_.Swap(&other->version_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
swap(source_context_, other->source_context_);
swap(syntax_, other->syntax_);
_internal_metadata_.Swap(&other->_internal_metadata_);
- swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata Api::GetMetadata() const {
@@ -777,17 +767,15 @@ const int Method::kSyntaxFieldNumber;
Method::Method()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
- if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
- ::protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsMethod();
- }
+ ::google::protobuf::internal::InitSCC(
+ &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Method.base);
SharedCtor();
// @@protoc_insertion_point(constructor:google.protobuf.Method)
}
Method::Method(const Method& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL),
- options_(from.options_),
- _cached_size_(0) {
+ options_(from.options_) {
_internal_metadata_.MergeFrom(from._internal_metadata_);
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.name().size() > 0) {
@@ -814,7 +802,6 @@ void Method::SharedCtor() {
::memset(&request_streaming_, 0, static_cast<size_t>(
reinterpret_cast<char*>(&syntax_) -
reinterpret_cast<char*>(&request_streaming_)) + sizeof(syntax_));
- _cached_size_ = 0;
}
Method::~Method() {
@@ -829,9 +816,7 @@ void Method::SharedDtor() {
}
void Method::SetCachedSize(int size) const {
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
+ _cached_size_.Set(size);
}
const ::google::protobuf::Descriptor* Method::descriptor() {
::protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce();
@@ -839,17 +824,10 @@ const ::google::protobuf::Descriptor* Method::descriptor() {
}
const Method& Method::default_instance() {
- ::protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsMethod();
+ ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Method.base);
return *internal_default_instance();
}
-Method* Method::New(::google::protobuf::Arena* arena) const {
- Method* n = new Method;
- if (arena != NULL) {
- arena->Own(n);
- }
- return n;
-}
void Method::Clear() {
// @@protoc_insertion_point(message_clear_start:google.protobuf.Method)
@@ -873,7 +851,7 @@ bool Method::MergePartialFromCodedStream(
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:google.protobuf.Method)
for (;;) {
- ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -957,7 +935,8 @@ bool Method::MergePartialFromCodedStream(
case 6: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
- DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_options()));
+ DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
+ input, add_options()));
} else {
goto handle_unusual;
}
@@ -968,7 +947,7 @@ bool Method::MergePartialFromCodedStream(
case 7: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(56u /* 56 & 0xFF */)) {
- int value;
+ int value = 0;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
@@ -1049,7 +1028,9 @@ void Method::SerializeWithCachedSizes(
for (unsigned int i = 0,
n = static_cast<unsigned int>(this->options_size()); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
- 6, this->options(static_cast<int>(i)), output);
+ 6,
+ this->options(static_cast<int>(i)),
+ output);
}
// .google.protobuf.Syntax syntax = 7;
@@ -1195,9 +1176,7 @@ size_t Method::ByteSizeLong() const {
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = cached_size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
+ SetCachedSize(cached_size);
return total_size;
}
@@ -1271,15 +1250,17 @@ void Method::Swap(Method* other) {
}
void Method::InternalSwap(Method* other) {
using std::swap;
- options_.InternalSwap(&other->options_);
- name_.Swap(&other->name_);
- request_type_url_.Swap(&other->request_type_url_);
- response_type_url_.Swap(&other->response_type_url_);
+ CastToBase(&options_)->InternalSwap(CastToBase(&other->options_));
+ name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ request_type_url_.Swap(&other->request_type_url_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ response_type_url_.Swap(&other->response_type_url_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
swap(request_streaming_, other->request_streaming_);
swap(response_streaming_, other->response_streaming_);
swap(syntax_, other->syntax_);
_internal_metadata_.Swap(&other->_internal_metadata_);
- swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata Method::GetMetadata() const {
@@ -1299,16 +1280,14 @@ const int Mixin::kRootFieldNumber;
Mixin::Mixin()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
- if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
- ::protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsMixin();
- }
+ ::google::protobuf::internal::InitSCC(
+ &protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Mixin.base);
SharedCtor();
// @@protoc_insertion_point(constructor:google.protobuf.Mixin)
}
Mixin::Mixin(const Mixin& from)
: ::google::protobuf::Message(),
- _internal_metadata_(NULL),
- _cached_size_(0) {
+ _internal_metadata_(NULL) {
_internal_metadata_.MergeFrom(from._internal_metadata_);
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.name().size() > 0) {
@@ -1324,7 +1303,6 @@ Mixin::Mixin(const Mixin& from)
void Mixin::SharedCtor() {
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
root_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
- _cached_size_ = 0;
}
Mixin::~Mixin() {
@@ -1338,9 +1316,7 @@ void Mixin::SharedDtor() {
}
void Mixin::SetCachedSize(int size) const {
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
+ _cached_size_.Set(size);
}
const ::google::protobuf::Descriptor* Mixin::descriptor() {
::protobuf_google_2fprotobuf_2fapi_2eproto::protobuf_AssignDescriptorsOnce();
@@ -1348,17 +1324,10 @@ const ::google::protobuf::Descriptor* Mixin::descriptor() {
}
const Mixin& Mixin::default_instance() {
- ::protobuf_google_2fprotobuf_2fapi_2eproto::InitDefaultsMixin();
+ ::google::protobuf::internal::InitSCC(&protobuf_google_2fprotobuf_2fapi_2eproto::scc_info_Mixin.base);
return *internal_default_instance();
}
-Mixin* Mixin::New(::google::protobuf::Arena* arena) const {
- Mixin* n = new Mixin;
- if (arena != NULL) {
- arena->Own(n);
- }
- return n;
-}
void Mixin::Clear() {
// @@protoc_insertion_point(message_clear_start:google.protobuf.Mixin)
@@ -1377,7 +1346,7 @@ bool Mixin::MergePartialFromCodedStream(
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:google.protobuf.Mixin)
for (;;) {
- ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+ ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
@@ -1527,9 +1496,7 @@ size_t Mixin::ByteSizeLong() const {
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
- GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
- _cached_size_ = cached_size;
- GOOGLE_SAFE_CONCURRENT_WRITES_END();
+ SetCachedSize(cached_size);
return total_size;
}
@@ -1589,10 +1556,11 @@ void Mixin::Swap(Mixin* other) {
}
void Mixin::InternalSwap(Mixin* other) {
using std::swap;
- name_.Swap(&other->name_);
- root_.Swap(&other->root_);
+ name_.Swap(&other->name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
+ root_.Swap(&other->root_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
+ GetArenaNoVirtual());
_internal_metadata_.Swap(&other->_internal_metadata_);
- swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata Mixin::GetMetadata() const {
@@ -1604,5 +1572,18 @@ void Mixin::InternalSwap(Mixin* other) {
// @@protoc_insertion_point(namespace_scope)
} // namespace protobuf
} // namespace google
+namespace google {
+namespace protobuf {
+template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::Api* Arena::CreateMaybeMessage< ::google::protobuf::Api >(Arena* arena) {
+ return Arena::CreateInternal< ::google::protobuf::Api >(arena);
+}
+template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::Method* Arena::CreateMaybeMessage< ::google::protobuf::Method >(Arena* arena) {
+ return Arena::CreateInternal< ::google::protobuf::Method >(arena);
+}
+template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::google::protobuf::Mixin* Arena::CreateMaybeMessage< ::google::protobuf::Mixin >(Arena* arena) {
+ return Arena::CreateInternal< ::google::protobuf::Mixin >(arena);
+}
+} // namespace protobuf
+} // namespace google
// @@protoc_insertion_point(global_scope)