types/cpp/metadata.pb.cc

1457 lines
52 KiB
C++
Raw Permalink Normal View History

// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: metadata.proto
#include "metadata.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// This is a temporary google only hack
#ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS
#include "third_party/protobuf/version.h"
#endif
// @@protoc_insertion_point(includes)
namespace protobuf_fee_2eproto {
extern PROTOBUF_INTERNAL_EXPORT_protobuf_fee_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_Fee;
} // namespace protobuf_fee_2eproto
namespace pb {
class MetadataDefaultTypeInternal {
public:
::google::protobuf::internal::ExplicitlyConstructed<Metadata>
_instance;
} _Metadata_default_instance_;
} // namespace pb
namespace protobuf_metadata_2eproto {
static void InitDefaultsMetadata() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
{
void* ptr = &::pb::_Metadata_default_instance_;
new (ptr) ::pb::Metadata();
::google::protobuf::internal::OnShutdownDestroyMessage(ptr);
}
::pb::Metadata::InitAsDefaultInstance();
}
::google::protobuf::internal::SCCInfo<1> scc_info_Metadata =
{{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsMetadata}, {
&protobuf_fee_2eproto::scc_info_Fee.base,}};
void InitDefaults() {
::google::protobuf::internal::InitSCC(&scc_info_Metadata.base);
}
::google::protobuf::Metadata file_level_metadata[1];
const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[2];
const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, _has_bits_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, _internal_metadata_),
~0u, // no _extensions_
~0u, // no _oneof_case_
~0u, // no _weak_field_map_
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, version_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, language_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, title_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, description_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, author_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, license_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, nsfw_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, fee_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, thumbnail_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, preview_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::pb::Metadata, licenseurl_),
8,
9,
0,
1,
2,
3,
10,
7,
4,
5,
6,
};
static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
{ 0, 16, sizeof(::pb::Metadata)},
};
static ::google::protobuf::Message const * const file_default_instances[] = {
reinterpret_cast<const ::google::protobuf::Message*>(&::pb::_Metadata_default_instance_),
};
void protobuf_AssignDescriptors() {
AddDescriptors();
AssignDescriptors(
"metadata.proto", schemas, file_default_instances, TableStruct::offsets,
file_level_metadata, file_level_enum_descriptors, NULL);
}
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;
void protobuf_RegisterTypes(const ::std::string&) {
protobuf_AssignDescriptorsOnce();
::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 1);
}
void AddDescriptorsImpl() {
InitDefaults();
static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
"\n\016metadata.proto\022\002pb\032\tfee.proto\"\347\016\n\010Meta"
"data\022%\n\007version\030\001 \002(\0162\024.pb.Metadata.Vers"
"ion\022\'\n\010language\030\002 \002(\0162\025.pb.Metadata.Lang"
"uage\022\r\n\005title\030\003 \002(\t\022\023\n\013description\030\004 \002(\t"
"\022\016\n\006author\030\005 \002(\t\022\017\n\007license\030\006 \002(\t\022\014\n\004nsf"
"w\030\007 \002(\010\022\024\n\003fee\030\010 \001(\0132\007.pb.Fee\022\021\n\tthumbna"
"il\030\t \001(\t\022\017\n\007preview\030\n \001(\t\022\022\n\nlicenseUrl\030"
"\013 \001(\t\"N\n\007Version\022\023\n\017UNKNOWN_VERSION\020\000\022\n\n"
"\006_0_0_1\020\001\022\n\n\006_0_0_2\020\002\022\n\n\006_0_0_3\020\003\022\n\n\006_0_"
"1_0\020\004\"\231\014\n\010Language\022\024\n\020UNKNOWN_LANGUAGE\020\000"
"\022\006\n\002en\020\001\022\006\n\002aa\020\002\022\006\n\002ab\020\003\022\006\n\002ae\020\004\022\006\n\002af\020\005"
"\022\006\n\002ak\020\006\022\006\n\002am\020\007\022\006\n\002an\020\010\022\006\n\002ar\020\t\022\006\n\002as\020\n"
"\022\006\n\002av\020\013\022\006\n\002ay\020\014\022\006\n\002az\020\r\022\006\n\002ba\020\016\022\006\n\002be\020\017"
"\022\006\n\002bg\020\020\022\006\n\002bh\020\021\022\006\n\002bi\020\022\022\006\n\002bm\020\023\022\006\n\002bn\020\024"
"\022\006\n\002bo\020\025\022\006\n\002br\020\026\022\006\n\002bs\020\027\022\006\n\002ca\020\030\022\006\n\002ce\020\031"
"\022\006\n\002ch\020\032\022\006\n\002co\020\033\022\006\n\002cr\020\034\022\006\n\002cs\020\035\022\006\n\002cu\020\036"
"\022\006\n\002cv\020\037\022\006\n\002cy\020 \022\006\n\002da\020!\022\006\n\002de\020\"\022\006\n\002dv\020#"
"\022\006\n\002dz\020$\022\006\n\002ee\020%\022\006\n\002el\020&\022\006\n\002eo\020\'\022\006\n\002es\020("
"\022\006\n\002et\020)\022\006\n\002eu\020*\022\006\n\002fa\020+\022\006\n\002ff\020,\022\006\n\002fi\020-"
"\022\006\n\002fj\020.\022\006\n\002fo\020/\022\006\n\002fr\0200\022\006\n\002fy\0201\022\006\n\002ga\0202"
"\022\006\n\002gd\0203\022\006\n\002gl\0204\022\006\n\002gn\0205\022\006\n\002gu\0206\022\006\n\002gv\0207"
"\022\006\n\002ha\0208\022\006\n\002he\0209\022\006\n\002hi\020:\022\006\n\002ho\020;\022\006\n\002hr\020<"
"\022\006\n\002ht\020=\022\006\n\002hu\020>\022\006\n\002hy\020\?\022\006\n\002hz\020@\022\006\n\002ia\020A"
"\022\006\n\002id\020B\022\006\n\002ie\020C\022\006\n\002ig\020D\022\006\n\002ii\020E\022\006\n\002ik\020F"
"\022\006\n\002io\020G\022\006\n\002is\020H\022\006\n\002it\020I\022\006\n\002iu\020J\022\006\n\002ja\020K"
"\022\006\n\002jv\020L\022\006\n\002ka\020M\022\006\n\002kg\020N\022\006\n\002ki\020O\022\006\n\002kj\020P"
"\022\006\n\002kk\020Q\022\006\n\002kl\020R\022\006\n\002km\020S\022\006\n\002kn\020T\022\006\n\002ko\020U"
"\022\006\n\002kr\020V\022\006\n\002ks\020W\022\006\n\002ku\020X\022\006\n\002kv\020Y\022\006\n\002kw\020Z"
"\022\006\n\002ky\020[\022\006\n\002la\020\\\022\006\n\002lb\020]\022\006\n\002lg\020^\022\006\n\002li\020_"
"\022\006\n\002ln\020`\022\006\n\002lo\020a\022\006\n\002lt\020b\022\006\n\002lu\020c\022\006\n\002lv\020d"
"\022\006\n\002mg\020e\022\006\n\002mh\020f\022\006\n\002mi\020g\022\006\n\002mk\020h\022\006\n\002ml\020i"
"\022\006\n\002mn\020j\022\006\n\002mr\020k\022\006\n\002ms\020l\022\006\n\002mt\020m\022\006\n\002my\020n"
"\022\006\n\002na\020o\022\006\n\002nb\020p\022\006\n\002nd\020q\022\006\n\002ne\020r\022\006\n\002ng\020s"
"\022\006\n\002nl\020t\022\006\n\002nn\020u\022\006\n\002no\020v\022\006\n\002nr\020w\022\006\n\002nv\020x"
"\022\006\n\002ny\020y\022\006\n\002oc\020z\022\006\n\002oj\020{\022\006\n\002om\020|\022\006\n\002or\020}"
"\022\006\n\002os\020~\022\006\n\002pa\020\177\022\007\n\002pi\020\200\001\022\007\n\002pl\020\201\001\022\007\n\002ps"
"\020\202\001\022\007\n\002pt\020\203\001\022\007\n\002qu\020\204\001\022\007\n\002rm\020\205\001\022\007\n\002rn\020\206\001\022"
"\007\n\002ro\020\207\001\022\007\n\002ru\020\210\001\022\007\n\002rw\020\211\001\022\007\n\002sa\020\212\001\022\007\n\002s"
"c\020\213\001\022\007\n\002sd\020\214\001\022\007\n\002se\020\215\001\022\007\n\002sg\020\216\001\022\007\n\002si\020\217\001"
"\022\007\n\002sk\020\220\001\022\007\n\002sl\020\221\001\022\007\n\002sm\020\222\001\022\007\n\002sn\020\223\001\022\007\n\002"
"so\020\224\001\022\007\n\002sq\020\225\001\022\007\n\002sr\020\226\001\022\007\n\002ss\020\227\001\022\007\n\002st\020\230"
"\001\022\007\n\002su\020\231\001\022\007\n\002sv\020\232\001\022\007\n\002sw\020\233\001\022\007\n\002ta\020\234\001\022\007\n"
"\002te\020\235\001\022\007\n\002tg\020\236\001\022\007\n\002th\020\237\001\022\007\n\002ti\020\240\001\022\007\n\002tk\020"
"\241\001\022\007\n\002tl\020\242\001\022\007\n\002tn\020\243\001\022\007\n\002to\020\244\001\022\007\n\002tr\020\245\001\022\007"
"\n\002ts\020\246\001\022\007\n\002tt\020\247\001\022\007\n\002tw\020\250\001\022\007\n\002ty\020\251\001\022\007\n\002ug"
"\020\252\001\022\007\n\002uk\020\253\001\022\007\n\002ur\020\254\001\022\007\n\002uz\020\255\001\022\007\n\002ve\020\256\001\022"
"\007\n\002vi\020\257\001\022\007\n\002vo\020\260\001\022\007\n\002wa\020\261\001\022\007\n\002wo\020\262\001\022\007\n\002x"
"h\020\263\001\022\007\n\002yi\020\264\001\022\007\n\002yo\020\265\001\022\007\n\002za\020\266\001\022\007\n\002zh\020\267\001"
"\022\007\n\002zu\020\270\001"
};
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
descriptor, 1929);
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
"metadata.proto", &protobuf_RegisterTypes);
::protobuf_fee_2eproto::AddDescriptors();
}
void AddDescriptors() {
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 {
StaticDescriptorInitializer() {
AddDescriptors();
}
} static_descriptor_initializer;
} // namespace protobuf_metadata_2eproto
namespace pb {
const ::google::protobuf::EnumDescriptor* Metadata_Version_descriptor() {
protobuf_metadata_2eproto::protobuf_AssignDescriptorsOnce();
return protobuf_metadata_2eproto::file_level_enum_descriptors[0];
}
bool Metadata_Version_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
case 3:
case 4:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const Metadata_Version Metadata::UNKNOWN_VERSION;
const Metadata_Version Metadata::_0_0_1;
const Metadata_Version Metadata::_0_0_2;
const Metadata_Version Metadata::_0_0_3;
const Metadata_Version Metadata::_0_1_0;
const Metadata_Version Metadata::Version_MIN;
const Metadata_Version Metadata::Version_MAX;
const int Metadata::Version_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* Metadata_Language_descriptor() {
protobuf_metadata_2eproto::protobuf_AssignDescriptorsOnce();
return protobuf_metadata_2eproto::file_level_enum_descriptors[1];
}
bool Metadata_Language_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
case 3:
case 4:
case 5:
case 6:
case 7:
case 8:
case 9:
case 10:
case 11:
case 12:
case 13:
case 14:
case 15:
case 16:
case 17:
case 18:
case 19:
case 20:
case 21:
case 22:
case 23:
case 24:
case 25:
case 26:
case 27:
case 28:
case 29:
case 30:
case 31:
case 32:
case 33:
case 34:
case 35:
case 36:
case 37:
case 38:
case 39:
case 40:
case 41:
case 42:
case 43:
case 44:
case 45:
case 46:
case 47:
case 48:
case 49:
case 50:
case 51:
case 52:
case 53:
case 54:
case 55:
case 56:
case 57:
case 58:
case 59:
case 60:
case 61:
case 62:
case 63:
case 64:
case 65:
case 66:
case 67:
case 68:
case 69:
case 70:
case 71:
case 72:
case 73:
case 74:
case 75:
case 76:
case 77:
case 78:
case 79:
case 80:
case 81:
case 82:
case 83:
case 84:
case 85:
case 86:
case 87:
case 88:
case 89:
case 90:
case 91:
case 92:
case 93:
case 94:
case 95:
case 96:
case 97:
case 98:
case 99:
case 100:
case 101:
case 102:
case 103:
case 104:
case 105:
case 106:
case 107:
case 108:
case 109:
case 110:
case 111:
case 112:
case 113:
case 114:
case 115:
case 116:
case 117:
case 118:
case 119:
case 120:
case 121:
case 122:
case 123:
case 124:
case 125:
case 126:
case 127:
case 128:
case 129:
case 130:
case 131:
case 132:
case 133:
case 134:
case 135:
case 136:
case 137:
case 138:
case 139:
case 140:
case 141:
case 142:
case 143:
case 144:
case 145:
case 146:
case 147:
case 148:
case 149:
case 150:
case 151:
case 152:
case 153:
case 154:
case 155:
case 156:
case 157:
case 158:
case 159:
case 160:
case 161:
case 162:
case 163:
case 164:
case 165:
case 166:
case 167:
case 168:
case 169:
case 170:
case 171:
case 172:
case 173:
case 174:
case 175:
case 176:
case 177:
case 178:
case 179:
case 180:
case 181:
case 182:
case 183:
case 184:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const Metadata_Language Metadata::UNKNOWN_LANGUAGE;
const Metadata_Language Metadata::en;
const Metadata_Language Metadata::aa;
const Metadata_Language Metadata::ab;
const Metadata_Language Metadata::ae;
const Metadata_Language Metadata::af;
const Metadata_Language Metadata::ak;
const Metadata_Language Metadata::am;
const Metadata_Language Metadata::an;
const Metadata_Language Metadata::ar;
const Metadata_Language Metadata::as;
const Metadata_Language Metadata::av;
const Metadata_Language Metadata::ay;
const Metadata_Language Metadata::az;
const Metadata_Language Metadata::ba;
const Metadata_Language Metadata::be;
const Metadata_Language Metadata::bg;
const Metadata_Language Metadata::bh;
const Metadata_Language Metadata::bi;
const Metadata_Language Metadata::bm;
const Metadata_Language Metadata::bn;
const Metadata_Language Metadata::bo;
const Metadata_Language Metadata::br;
const Metadata_Language Metadata::bs;
const Metadata_Language Metadata::ca;
const Metadata_Language Metadata::ce;
const Metadata_Language Metadata::ch;
const Metadata_Language Metadata::co;
const Metadata_Language Metadata::cr;
const Metadata_Language Metadata::cs;
const Metadata_Language Metadata::cu;
const Metadata_Language Metadata::cv;
const Metadata_Language Metadata::cy;
const Metadata_Language Metadata::da;
const Metadata_Language Metadata::de;
const Metadata_Language Metadata::dv;
const Metadata_Language Metadata::dz;
const Metadata_Language Metadata::ee;
const Metadata_Language Metadata::el;
const Metadata_Language Metadata::eo;
const Metadata_Language Metadata::es;
const Metadata_Language Metadata::et;
const Metadata_Language Metadata::eu;
const Metadata_Language Metadata::fa;
const Metadata_Language Metadata::ff;
const Metadata_Language Metadata::fi;
const Metadata_Language Metadata::fj;
const Metadata_Language Metadata::fo;
const Metadata_Language Metadata::fr;
const Metadata_Language Metadata::fy;
const Metadata_Language Metadata::ga;
const Metadata_Language Metadata::gd;
const Metadata_Language Metadata::gl;
const Metadata_Language Metadata::gn;
const Metadata_Language Metadata::gu;
const Metadata_Language Metadata::gv;
const Metadata_Language Metadata::ha;
const Metadata_Language Metadata::he;
const Metadata_Language Metadata::hi;
const Metadata_Language Metadata::ho;
const Metadata_Language Metadata::hr;
const Metadata_Language Metadata::ht;
const Metadata_Language Metadata::hu;
const Metadata_Language Metadata::hy;
const Metadata_Language Metadata::hz;
const Metadata_Language Metadata::ia;
const Metadata_Language Metadata::id;
const Metadata_Language Metadata::ie;
const Metadata_Language Metadata::ig;
const Metadata_Language Metadata::ii;
const Metadata_Language Metadata::ik;
const Metadata_Language Metadata::io;
const Metadata_Language Metadata::is;
const Metadata_Language Metadata::it;
const Metadata_Language Metadata::iu;
const Metadata_Language Metadata::ja;
const Metadata_Language Metadata::jv;
const Metadata_Language Metadata::ka;
const Metadata_Language Metadata::kg;
const Metadata_Language Metadata::ki;
const Metadata_Language Metadata::kj;
const Metadata_Language Metadata::kk;
const Metadata_Language Metadata::kl;
const Metadata_Language Metadata::km;
const Metadata_Language Metadata::kn;
const Metadata_Language Metadata::ko;
const Metadata_Language Metadata::kr;
const Metadata_Language Metadata::ks;
const Metadata_Language Metadata::ku;
const Metadata_Language Metadata::kv;
const Metadata_Language Metadata::kw;
const Metadata_Language Metadata::ky;
const Metadata_Language Metadata::la;
const Metadata_Language Metadata::lb;
const Metadata_Language Metadata::lg;
const Metadata_Language Metadata::li;
const Metadata_Language Metadata::ln;
const Metadata_Language Metadata::lo;
const Metadata_Language Metadata::lt;
const Metadata_Language Metadata::lu;
const Metadata_Language Metadata::lv;
const Metadata_Language Metadata::mg;
const Metadata_Language Metadata::mh;
const Metadata_Language Metadata::mi;
const Metadata_Language Metadata::mk;
const Metadata_Language Metadata::ml;
const Metadata_Language Metadata::mn;
const Metadata_Language Metadata::mr;
const Metadata_Language Metadata::ms;
const Metadata_Language Metadata::mt;
const Metadata_Language Metadata::my;
const Metadata_Language Metadata::na;
const Metadata_Language Metadata::nb;
const Metadata_Language Metadata::nd;
const Metadata_Language Metadata::ne;
const Metadata_Language Metadata::ng;
const Metadata_Language Metadata::nl;
const Metadata_Language Metadata::nn;
const Metadata_Language Metadata::no;
const Metadata_Language Metadata::nr;
const Metadata_Language Metadata::nv;
const Metadata_Language Metadata::ny;
const Metadata_Language Metadata::oc;
const Metadata_Language Metadata::oj;
const Metadata_Language Metadata::om;
const Metadata_Language Metadata::or_;
const Metadata_Language Metadata::os;
const Metadata_Language Metadata::pa;
const Metadata_Language Metadata::pi;
const Metadata_Language Metadata::pl;
const Metadata_Language Metadata::ps;
const Metadata_Language Metadata::pt;
const Metadata_Language Metadata::qu;
const Metadata_Language Metadata::rm;
const Metadata_Language Metadata::rn;
const Metadata_Language Metadata::ro;
const Metadata_Language Metadata::ru;
const Metadata_Language Metadata::rw;
const Metadata_Language Metadata::sa;
const Metadata_Language Metadata::sc;
const Metadata_Language Metadata::sd;
const Metadata_Language Metadata::se;
const Metadata_Language Metadata::sg;
const Metadata_Language Metadata::si;
const Metadata_Language Metadata::sk;
const Metadata_Language Metadata::sl;
const Metadata_Language Metadata::sm;
const Metadata_Language Metadata::sn;
const Metadata_Language Metadata::so;
const Metadata_Language Metadata::sq;
const Metadata_Language Metadata::sr;
const Metadata_Language Metadata::ss;
const Metadata_Language Metadata::st;
const Metadata_Language Metadata::su;
const Metadata_Language Metadata::sv;
const Metadata_Language Metadata::sw;
const Metadata_Language Metadata::ta;
const Metadata_Language Metadata::te;
const Metadata_Language Metadata::tg;
const Metadata_Language Metadata::th;
const Metadata_Language Metadata::ti;
const Metadata_Language Metadata::tk;
const Metadata_Language Metadata::tl;
const Metadata_Language Metadata::tn;
const Metadata_Language Metadata::to;
const Metadata_Language Metadata::tr;
const Metadata_Language Metadata::ts;
const Metadata_Language Metadata::tt;
const Metadata_Language Metadata::tw;
const Metadata_Language Metadata::ty;
const Metadata_Language Metadata::ug;
const Metadata_Language Metadata::uk;
const Metadata_Language Metadata::ur;
const Metadata_Language Metadata::uz;
const Metadata_Language Metadata::ve;
const Metadata_Language Metadata::vi;
const Metadata_Language Metadata::vo;
const Metadata_Language Metadata::wa;
const Metadata_Language Metadata::wo;
const Metadata_Language Metadata::xh;
const Metadata_Language Metadata::yi;
const Metadata_Language Metadata::yo;
const Metadata_Language Metadata::za;
const Metadata_Language Metadata::zh;
const Metadata_Language Metadata::zu;
const Metadata_Language Metadata::Language_MIN;
const Metadata_Language Metadata::Language_MAX;
const int Metadata::Language_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
// ===================================================================
void Metadata::InitAsDefaultInstance() {
::pb::_Metadata_default_instance_._instance.get_mutable()->fee_ = const_cast< ::pb::Fee*>(
::pb::Fee::internal_default_instance());
}
void Metadata::clear_fee() {
if (fee_ != NULL) fee_->Clear();
clear_has_fee();
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int Metadata::kVersionFieldNumber;
const int Metadata::kLanguageFieldNumber;
const int Metadata::kTitleFieldNumber;
const int Metadata::kDescriptionFieldNumber;
const int Metadata::kAuthorFieldNumber;
const int Metadata::kLicenseFieldNumber;
const int Metadata::kNsfwFieldNumber;
const int Metadata::kFeeFieldNumber;
const int Metadata::kThumbnailFieldNumber;
const int Metadata::kPreviewFieldNumber;
const int Metadata::kLicenseUrlFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
Metadata::Metadata()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
::google::protobuf::internal::InitSCC(
&protobuf_metadata_2eproto::scc_info_Metadata.base);
SharedCtor();
// @@protoc_insertion_point(constructor:pb.Metadata)
}
Metadata::Metadata(const Metadata& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL),
_has_bits_(from._has_bits_) {
_internal_metadata_.MergeFrom(from._internal_metadata_);
title_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_title()) {
title_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.title_);
}
description_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_description()) {
description_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.description_);
}
author_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_author()) {
author_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.author_);
}
license_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_license()) {
license_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.license_);
}
thumbnail_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_thumbnail()) {
thumbnail_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.thumbnail_);
}
preview_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_preview()) {
preview_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.preview_);
}
licenseurl_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.has_licenseurl()) {
licenseurl_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.licenseurl_);
}
if (from.has_fee()) {
fee_ = new ::pb::Fee(*from.fee_);
} else {
fee_ = NULL;
}
::memcpy(&version_, &from.version_,
static_cast<size_t>(reinterpret_cast<char*>(&nsfw_) -
reinterpret_cast<char*>(&version_)) + sizeof(nsfw_));
// @@protoc_insertion_point(copy_constructor:pb.Metadata)
}
void Metadata::SharedCtor() {
title_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
description_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
author_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
license_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
thumbnail_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
preview_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
licenseurl_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&fee_, 0, static_cast<size_t>(
reinterpret_cast<char*>(&nsfw_) -
reinterpret_cast<char*>(&fee_)) + sizeof(nsfw_));
}
Metadata::~Metadata() {
// @@protoc_insertion_point(destructor:pb.Metadata)
SharedDtor();
}
void Metadata::SharedDtor() {
title_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
description_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
author_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
license_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
thumbnail_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
preview_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
licenseurl_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (this != internal_default_instance()) delete fee_;
}
void Metadata::SetCachedSize(int size) const {
_cached_size_.Set(size);
}
const ::google::protobuf::Descriptor* Metadata::descriptor() {
::protobuf_metadata_2eproto::protobuf_AssignDescriptorsOnce();
return ::protobuf_metadata_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
}
const Metadata& Metadata::default_instance() {
::google::protobuf::internal::InitSCC(&protobuf_metadata_2eproto::scc_info_Metadata.base);
return *internal_default_instance();
}
void Metadata::Clear() {
// @@protoc_insertion_point(message_clear_start:pb.Metadata)
::google::protobuf::uint32 cached_has_bits = 0;
// Prevent compiler warnings about cached_has_bits being unused
(void) cached_has_bits;
cached_has_bits = _has_bits_[0];
if (cached_has_bits & 255u) {
if (cached_has_bits & 0x00000001u) {
title_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000002u) {
description_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000004u) {
author_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000008u) {
license_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000010u) {
thumbnail_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000020u) {
preview_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000040u) {
licenseurl_.ClearNonDefaultToEmptyNoArena();
}
if (cached_has_bits & 0x00000080u) {
GOOGLE_DCHECK(fee_ != NULL);
fee_->Clear();
}
}
if (cached_has_bits & 1792u) {
::memset(&version_, 0, static_cast<size_t>(
reinterpret_cast<char*>(&nsfw_) -
reinterpret_cast<char*>(&version_)) + sizeof(nsfw_));
}
_has_bits_.Clear();
_internal_metadata_.Clear();
}
bool Metadata::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:pb.Metadata)
for (;;) {
::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)) {
// required .pb.Metadata.Version version = 1;
case 1: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::pb::Metadata_Version_IsValid(value)) {
set_version(static_cast< ::pb::Metadata_Version >(value));
} else {
mutable_unknown_fields()->AddVarint(
1, static_cast< ::google::protobuf::uint64>(value));
}
} else {
goto handle_unusual;
}
break;
}
// required .pb.Metadata.Language language = 2;
case 2: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::pb::Metadata_Language_IsValid(value)) {
set_language(static_cast< ::pb::Metadata_Language >(value));
} else {
mutable_unknown_fields()->AddVarint(
2, static_cast< ::google::protobuf::uint64>(value));
}
} else {
goto handle_unusual;
}
break;
}
// required string title = 3;
case 3: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_title()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->title().data(), static_cast<int>(this->title().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.title");
} else {
goto handle_unusual;
}
break;
}
// required string description = 4;
case 4: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_description()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->description().data(), static_cast<int>(this->description().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.description");
} else {
goto handle_unusual;
}
break;
}
// required string author = 5;
case 5: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_author()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->author().data(), static_cast<int>(this->author().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.author");
} else {
goto handle_unusual;
}
break;
}
// required string license = 6;
case 6: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_license()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->license().data(), static_cast<int>(this->license().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.license");
} else {
goto handle_unusual;
}
break;
}
// required bool nsfw = 7;
case 7: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(56u /* 56 & 0xFF */)) {
set_has_nsfw();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &nsfw_)));
} else {
goto handle_unusual;
}
break;
}
// optional .pb.Fee fee = 8;
case 8: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(66u /* 66 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(
input, mutable_fee()));
} else {
goto handle_unusual;
}
break;
}
// optional string thumbnail = 9;
case 9: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(74u /* 74 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_thumbnail()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->thumbnail().data(), static_cast<int>(this->thumbnail().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.thumbnail");
} else {
goto handle_unusual;
}
break;
}
// optional string preview = 10;
case 10: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(82u /* 82 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_preview()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->preview().data(), static_cast<int>(this->preview().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.preview");
} else {
goto handle_unusual;
}
break;
}
// optional string licenseUrl = 11;
case 11: {
if (static_cast< ::google::protobuf::uint8>(tag) ==
static_cast< ::google::protobuf::uint8>(90u /* 90 & 0xFF */)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_licenseurl()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->licenseurl().data(), static_cast<int>(this->licenseurl().length()),
::google::protobuf::internal::WireFormat::PARSE,
"pb.Metadata.licenseUrl");
} else {
goto handle_unusual;
}
break;
}
default: {
handle_unusual:
if (tag == 0) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, _internal_metadata_.mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:pb.Metadata)
return true;
failure:
// @@protoc_insertion_point(parse_failure:pb.Metadata)
return false;
#undef DO_
}
void Metadata::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:pb.Metadata)
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
cached_has_bits = _has_bits_[0];
// required .pb.Metadata.Version version = 1;
if (cached_has_bits & 0x00000100u) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->version(), output);
}
// required .pb.Metadata.Language language = 2;
if (cached_has_bits & 0x00000200u) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
2, this->language(), output);
}
// required string title = 3;
if (cached_has_bits & 0x00000001u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->title().data(), static_cast<int>(this->title().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.title");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
3, this->title(), output);
}
// required string description = 4;
if (cached_has_bits & 0x00000002u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->description().data(), static_cast<int>(this->description().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.description");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
4, this->description(), output);
}
// required string author = 5;
if (cached_has_bits & 0x00000004u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->author().data(), static_cast<int>(this->author().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.author");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
5, this->author(), output);
}
// required string license = 6;
if (cached_has_bits & 0x00000008u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->license().data(), static_cast<int>(this->license().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.license");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
6, this->license(), output);
}
// required bool nsfw = 7;
if (cached_has_bits & 0x00000400u) {
::google::protobuf::internal::WireFormatLite::WriteBool(7, this->nsfw(), output);
}
// optional .pb.Fee fee = 8;
if (cached_has_bits & 0x00000080u) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
8, this->_internal_fee(), output);
}
// optional string thumbnail = 9;
if (cached_has_bits & 0x00000010u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->thumbnail().data(), static_cast<int>(this->thumbnail().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.thumbnail");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
9, this->thumbnail(), output);
}
// optional string preview = 10;
if (cached_has_bits & 0x00000020u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->preview().data(), static_cast<int>(this->preview().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.preview");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
10, this->preview(), output);
}
// optional string licenseUrl = 11;
if (cached_has_bits & 0x00000040u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->licenseurl().data(), static_cast<int>(this->licenseurl().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.licenseUrl");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
11, this->licenseurl(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
_internal_metadata_.unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:pb.Metadata)
}
::google::protobuf::uint8* Metadata::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:pb.Metadata)
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
cached_has_bits = _has_bits_[0];
// required .pb.Metadata.Version version = 1;
if (cached_has_bits & 0x00000100u) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->version(), target);
}
// required .pb.Metadata.Language language = 2;
if (cached_has_bits & 0x00000200u) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
2, this->language(), target);
}
// required string title = 3;
if (cached_has_bits & 0x00000001u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->title().data(), static_cast<int>(this->title().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.title");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
3, this->title(), target);
}
// required string description = 4;
if (cached_has_bits & 0x00000002u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->description().data(), static_cast<int>(this->description().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.description");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
4, this->description(), target);
}
// required string author = 5;
if (cached_has_bits & 0x00000004u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->author().data(), static_cast<int>(this->author().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.author");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
5, this->author(), target);
}
// required string license = 6;
if (cached_has_bits & 0x00000008u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->license().data(), static_cast<int>(this->license().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.license");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
6, this->license(), target);
}
// required bool nsfw = 7;
if (cached_has_bits & 0x00000400u) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(7, this->nsfw(), target);
}
// optional .pb.Fee fee = 8;
if (cached_has_bits & 0x00000080u) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageToArray(
8, this->_internal_fee(), deterministic, target);
}
// optional string thumbnail = 9;
if (cached_has_bits & 0x00000010u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->thumbnail().data(), static_cast<int>(this->thumbnail().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.thumbnail");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
9, this->thumbnail(), target);
}
// optional string preview = 10;
if (cached_has_bits & 0x00000020u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->preview().data(), static_cast<int>(this->preview().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.preview");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
10, this->preview(), target);
}
// optional string licenseUrl = 11;
if (cached_has_bits & 0x00000040u) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->licenseurl().data(), static_cast<int>(this->licenseurl().length()),
::google::protobuf::internal::WireFormat::SERIALIZE,
"pb.Metadata.licenseUrl");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
11, this->licenseurl(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
_internal_metadata_.unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:pb.Metadata)
return target;
}
size_t Metadata::RequiredFieldsByteSizeFallback() const {
// @@protoc_insertion_point(required_fields_byte_size_fallback_start:pb.Metadata)
size_t total_size = 0;
if (has_title()) {
// required string title = 3;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->title());
}
if (has_description()) {
// required string description = 4;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->description());
}
if (has_author()) {
// required string author = 5;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->author());
}
if (has_license()) {
// required string license = 6;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->license());
}
if (has_version()) {
// required .pb.Metadata.Version version = 1;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->version());
}
if (has_language()) {
// required .pb.Metadata.Language language = 2;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->language());
}
if (has_nsfw()) {
// required bool nsfw = 7;
total_size += 1 + 1;
}
return total_size;
}
size_t Metadata::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:pb.Metadata)
size_t total_size = 0;
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
_internal_metadata_.unknown_fields());
}
if (((_has_bits_[0] & 0x0000070f) ^ 0x0000070f) == 0) { // All required fields are present.
// required string title = 3;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->title());
// required string description = 4;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->description());
// required string author = 5;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->author());
// required string license = 6;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->license());
// required .pb.Metadata.Version version = 1;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->version());
// required .pb.Metadata.Language language = 2;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->language());
// required bool nsfw = 7;
total_size += 1 + 1;
} else {
total_size += RequiredFieldsByteSizeFallback();
}
if (_has_bits_[0 / 32] & 240u) {
// optional string thumbnail = 9;
if (has_thumbnail()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->thumbnail());
}
// optional string preview = 10;
if (has_preview()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->preview());
}
// optional string licenseUrl = 11;
if (has_licenseurl()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->licenseurl());
}
// optional .pb.Fee fee = 8;
if (has_fee()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSize(
*fee_);
}
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
SetCachedSize(cached_size);
return total_size;
}
void Metadata::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:pb.Metadata)
GOOGLE_DCHECK_NE(&from, this);
const Metadata* source =
::google::protobuf::internal::DynamicCastToGenerated<const Metadata>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:pb.Metadata)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:pb.Metadata)
MergeFrom(*source);
}
}
void Metadata::MergeFrom(const Metadata& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:pb.Metadata)
GOOGLE_DCHECK_NE(&from, this);
_internal_metadata_.MergeFrom(from._internal_metadata_);
::google::protobuf::uint32 cached_has_bits = 0;
(void) cached_has_bits;
cached_has_bits = from._has_bits_[0];
if (cached_has_bits & 255u) {
if (cached_has_bits & 0x00000001u) {
set_has_title();
title_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.title_);
}
if (cached_has_bits & 0x00000002u) {
set_has_description();
description_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.description_);
}
if (cached_has_bits & 0x00000004u) {
set_has_author();
author_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.author_);
}
if (cached_has_bits & 0x00000008u) {
set_has_license();
license_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.license_);
}
if (cached_has_bits & 0x00000010u) {
set_has_thumbnail();
thumbnail_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.thumbnail_);
}
if (cached_has_bits & 0x00000020u) {
set_has_preview();
preview_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.preview_);
}
if (cached_has_bits & 0x00000040u) {
set_has_licenseurl();
licenseurl_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.licenseurl_);
}
if (cached_has_bits & 0x00000080u) {
mutable_fee()->::pb::Fee::MergeFrom(from.fee());
}
}
if (cached_has_bits & 1792u) {
if (cached_has_bits & 0x00000100u) {
version_ = from.version_;
}
if (cached_has_bits & 0x00000200u) {
language_ = from.language_;
}
if (cached_has_bits & 0x00000400u) {
nsfw_ = from.nsfw_;
}
_has_bits_[0] |= cached_has_bits;
}
}
void Metadata::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:pb.Metadata)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void Metadata::CopyFrom(const Metadata& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:pb.Metadata)
if (&from == this) return;
Clear();
MergeFrom(from);
}
bool Metadata::IsInitialized() const {
if ((_has_bits_[0] & 0x0000070f) != 0x0000070f) return false;
if (has_fee()) {
if (!this->fee_->IsInitialized()) return false;
}
return true;
}
void Metadata::Swap(Metadata* other) {
if (other == this) return;
InternalSwap(other);
}
void Metadata::InternalSwap(Metadata* other) {
using std::swap;
title_.Swap(&other->title_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
description_.Swap(&other->description_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
author_.Swap(&other->author_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
license_.Swap(&other->license_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
thumbnail_.Swap(&other->thumbnail_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
preview_.Swap(&other->preview_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
licenseurl_.Swap(&other->licenseurl_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
swap(fee_, other->fee_);
swap(version_, other->version_);
swap(language_, other->language_);
swap(nsfw_, other->nsfw_);
swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
}
::google::protobuf::Metadata Metadata::GetMetadata() const {
protobuf_metadata_2eproto::protobuf_AssignDescriptorsOnce();
return ::protobuf_metadata_2eproto::file_level_metadata[kIndexInFileMessages];
}
// @@protoc_insertion_point(namespace_scope)
} // namespace pb
namespace google {
namespace protobuf {
template<> GOOGLE_PROTOBUF_ATTRIBUTE_NOINLINE ::pb::Metadata* Arena::CreateMaybeMessage< ::pb::Metadata >(Arena* arena) {
return Arena::CreateInternal< ::pb::Metadata >(arena);
}
} // namespace protobuf
} // namespace google
// @@protoc_insertion_point(global_scope)