Drizzled Public API Documentation

event.pb.cc
1 // Generated by the protocol buffer compiler. DO NOT EDIT!
2 // source: event.proto
3 
4 #define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
5 #include "event.pb.h"
6 
7 #include <algorithm>
8 
9 #include <google/protobuf/stubs/common.h>
10 #include <google/protobuf/stubs/once.h>
11 #include <google/protobuf/io/coded_stream.h>
12 #include <google/protobuf/wire_format_lite_inl.h>
13 #include <google/protobuf/descriptor.h>
14 #include <google/protobuf/generated_message_reflection.h>
15 #include <google/protobuf/reflection_ops.h>
16 #include <google/protobuf/wire_format.h>
17 // @@protoc_insertion_point(includes)
18 
19 namespace drizzled {
20 namespace message {
21 
22 namespace {
23 
24 const ::google::protobuf::Descriptor* Event_descriptor_ = NULL;
25 const ::google::protobuf::internal::GeneratedMessageReflection*
26  Event_reflection_ = NULL;
27 const ::google::protobuf::EnumDescriptor* Event_Type_descriptor_ = NULL;
28 
29 } // namespace
30 
31 
32 void protobuf_AssignDesc_event_2eproto() {
33  protobuf_AddDesc_event_2eproto();
34  const ::google::protobuf::FileDescriptor* file =
35  ::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
36  "event.proto");
37  GOOGLE_CHECK(file != NULL);
38  Event_descriptor_ = file->message_type(0);
39  static const int Event_offsets_[1] = {
40  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Event, type_),
41  };
42  Event_reflection_ =
43  new ::google::protobuf::internal::GeneratedMessageReflection(
44  Event_descriptor_,
45  Event::default_instance_,
46  Event_offsets_,
47  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Event, _has_bits_[0]),
48  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Event, _unknown_fields_),
49  -1,
50  ::google::protobuf::DescriptorPool::generated_pool(),
51  ::google::protobuf::MessageFactory::generated_factory(),
52  sizeof(Event));
53  Event_Type_descriptor_ = Event_descriptor_->enum_type(0);
54 }
55 
56 namespace {
57 
58 GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
59 inline void protobuf_AssignDescriptorsOnce() {
60  ::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
61  &protobuf_AssignDesc_event_2eproto);
62 }
63 
64 void protobuf_RegisterTypes(const ::std::string&) {
65  protobuf_AssignDescriptorsOnce();
66  ::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
67  Event_descriptor_, &Event::default_instance());
68 }
69 
70 } // namespace
71 
72 void protobuf_ShutdownFile_event_2eproto() {
73  delete Event::default_instance_;
74  delete Event_reflection_;
75 }
76 
77 void protobuf_AddDesc_event_2eproto() {
78  static bool already_here = false;
79  if (already_here) return;
80  already_here = true;
81  GOOGLE_PROTOBUF_VERIFY_VERSION;
82 
83  ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
84  "\n\013event.proto\022\020drizzled.message\"V\n\005Event"
85  "\022*\n\004type\030\001 \002(\0162\034.drizzled.message.Event."
86  "Type\"!\n\004Type\022\013\n\007STARTUP\020\000\022\014\n\010SHUTDOWN\020\001B"
87  "&\n\024org.drizzle.messagesB\014EventMessageH\001", 159);
88  ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
89  "event.proto", &protobuf_RegisterTypes);
90  Event::default_instance_ = new Event();
91  Event::default_instance_->InitAsDefaultInstance();
92  ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_event_2eproto);
93 }
94 
95 // Force AddDescriptors() to be called at static initialization time.
98  protobuf_AddDesc_event_2eproto();
99  }
100 } static_descriptor_initializer_event_2eproto_;
101 
102 // ===================================================================
103 
104 const ::google::protobuf::EnumDescriptor* Event_Type_descriptor() {
105  protobuf_AssignDescriptorsOnce();
106  return Event_Type_descriptor_;
107 }
108 bool Event_Type_IsValid(int value) {
109  switch(value) {
110  case 0:
111  case 1:
112  return true;
113  default:
114  return false;
115  }
116 }
117 
118 #ifndef _MSC_VER
119 const Event_Type Event::STARTUP;
120 const Event_Type Event::SHUTDOWN;
121 const Event_Type Event::Type_MIN;
122 const Event_Type Event::Type_MAX;
123 const int Event::Type_ARRAYSIZE;
124 #endif // _MSC_VER
125 #ifndef _MSC_VER
126 const int Event::kTypeFieldNumber;
127 #endif // !_MSC_VER
128 
129 Event::Event()
130  : ::google::protobuf::Message() {
131  SharedCtor();
132 }
133 
134 void Event::InitAsDefaultInstance() {
135 }
136 
137 Event::Event(const Event& from)
138  : ::google::protobuf::Message() {
139  SharedCtor();
140  MergeFrom(from);
141 }
142 
143 void Event::SharedCtor() {
144  _cached_size_ = 0;
145  type_ = 0;
146  ::memset(_has_bits_, 0, sizeof(_has_bits_));
147 }
148 
149 Event::~Event() {
150  SharedDtor();
151 }
152 
153 void Event::SharedDtor() {
154  if (this != default_instance_) {
155  }
156 }
157 
158 void Event::SetCachedSize(int size) const {
159  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
160  _cached_size_ = size;
161  GOOGLE_SAFE_CONCURRENT_WRITES_END();
162 }
163 const ::google::protobuf::Descriptor* Event::descriptor() {
164  protobuf_AssignDescriptorsOnce();
165  return Event_descriptor_;
166 }
167 
168 const Event& Event::default_instance() {
169  if (default_instance_ == NULL) protobuf_AddDesc_event_2eproto();
170  return *default_instance_;
171 }
172 
173 Event* Event::default_instance_ = NULL;
174 
175 Event* Event::New() const {
176  return new Event;
177 }
178 
179 void Event::Clear() {
180  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
181  type_ = 0;
182  }
183  ::memset(_has_bits_, 0, sizeof(_has_bits_));
184  mutable_unknown_fields()->Clear();
185 }
186 
187 bool Event::MergePartialFromCodedStream(
188  ::google::protobuf::io::CodedInputStream* input) {
189 #define DO_(EXPRESSION) if (!(EXPRESSION)) return false
190  ::google::protobuf::uint32 tag;
191  while ((tag = input->ReadTag()) != 0) {
192  switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
193  // required .drizzled.message.Event.Type type = 1;
194  case 1: {
195  if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
196  ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
197  int value;
198  DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
199  int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
200  input, &value)));
201  if (::drizzled::message::Event_Type_IsValid(value)) {
202  set_type(static_cast< ::drizzled::message::Event_Type >(value));
203  } else {
204  mutable_unknown_fields()->AddVarint(1, value);
205  }
206  } else {
207  goto handle_uninterpreted;
208  }
209  if (input->ExpectAtEnd()) return true;
210  break;
211  }
212 
213  default: {
214  handle_uninterpreted:
215  if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
216  ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
217  return true;
218  }
219  DO_(::google::protobuf::internal::WireFormat::SkipField(
220  input, tag, mutable_unknown_fields()));
221  break;
222  }
223  }
224  }
225  return true;
226 #undef DO_
227 }
228 
229 void Event::SerializeWithCachedSizes(
230  ::google::protobuf::io::CodedOutputStream* output) const {
231  // required .drizzled.message.Event.Type type = 1;
232  if (has_type()) {
233  ::google::protobuf::internal::WireFormatLite::WriteEnum(
234  1, this->type(), output);
235  }
236 
237  if (!unknown_fields().empty()) {
238  ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
239  unknown_fields(), output);
240  }
241 }
242 
243 ::google::protobuf::uint8* Event::SerializeWithCachedSizesToArray(
244  ::google::protobuf::uint8* target) const {
245  // required .drizzled.message.Event.Type type = 1;
246  if (has_type()) {
247  target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
248  1, this->type(), target);
249  }
250 
251  if (!unknown_fields().empty()) {
252  target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
253  unknown_fields(), target);
254  }
255  return target;
256 }
257 
258 int Event::ByteSize() const {
259  int total_size = 0;
260 
261  if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) {
262  // required .drizzled.message.Event.Type type = 1;
263  if (has_type()) {
264  total_size += 1 +
265  ::google::protobuf::internal::WireFormatLite::EnumSize(this->type());
266  }
267 
268  }
269  if (!unknown_fields().empty()) {
270  total_size +=
271  ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
272  unknown_fields());
273  }
274  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
275  _cached_size_ = total_size;
276  GOOGLE_SAFE_CONCURRENT_WRITES_END();
277  return total_size;
278 }
279 
280 void Event::MergeFrom(const ::google::protobuf::Message& from) {
281  GOOGLE_CHECK_NE(&from, this);
282  const Event* source =
283  ::google::protobuf::internal::dynamic_cast_if_available<const Event*>(
284  &from);
285  if (source == NULL) {
286  ::google::protobuf::internal::ReflectionOps::Merge(from, this);
287  } else {
288  MergeFrom(*source);
289  }
290 }
291 
292 void Event::MergeFrom(const Event& from) {
293  GOOGLE_CHECK_NE(&from, this);
294  if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
295  if (from.has_type()) {
296  set_type(from.type());
297  }
298  }
299  mutable_unknown_fields()->MergeFrom(from.unknown_fields());
300 }
301 
302 void Event::CopyFrom(const ::google::protobuf::Message& from) {
303  if (&from == this) return;
304  Clear();
305  MergeFrom(from);
306 }
307 
308 void Event::CopyFrom(const Event& from) {
309  if (&from == this) return;
310  Clear();
311  MergeFrom(from);
312 }
313 
314 bool Event::IsInitialized() const {
315  if ((_has_bits_[0] & 0x00000001) != 0x00000001) return false;
316 
317  return true;
318 }
319 
320 void Event::Swap(Event* other) {
321  if (other != this) {
322  std::swap(type_, other->type_);
323  std::swap(_has_bits_[0], other->_has_bits_[0]);
324  _unknown_fields_.Swap(&other->_unknown_fields_);
325  std::swap(_cached_size_, other->_cached_size_);
326  }
327 }
328 
329 ::google::protobuf::Metadata Event::GetMetadata() const {
330  protobuf_AssignDescriptorsOnce();
331  ::google::protobuf::Metadata metadata;
332  metadata.descriptor = Event_descriptor_;
333  metadata.reflection = Event_reflection_;
334  return metadata;
335 }
336 
337 
338 // @@protoc_insertion_point(namespace_scope)
339 
340 } // namespace message
341 } // namespace drizzled
342 
343 // @@protoc_insertion_point(global_scope)