Thrift: Limited Reflection for C++.

Summary:
The Thrift compiler now generates static methods for every service to generate
a reflection of the methods provided by the service.  This reflection is fairly
limited, but should be enough for what we want to do with SMC.

Reviewed By: mcslee

Test Plan: test/ReflectionTest.cpp

Revert Plan: ok


git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665226 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/cpp/src/TLogging.h b/lib/cpp/src/TLogging.h
index 15c9c06..4d3060d 100644
--- a/lib/cpp/src/TLogging.h
+++ b/lib/cpp/src/TLogging.h
@@ -4,8 +4,8 @@
 // See accompanying file LICENSE or visit the Thrift site at:
 // http://developers.facebook.com/thrift/
 
-#ifndef _THRIFT_LOGGING_H
-#define _THRIFT_LOGGING_H 1
+#ifndef _THRIFT_TLOGGING_H_
+#define _THRIFT_TLOGGING_H_ 1
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -148,4 +148,4 @@
   #define T_LOG_OPER(format_string,...)
 #endif
 
-#endif	// _THRIFT_LOGGING_H
+#endif // #ifndef _THRIFT_TLOGGING_H_
diff --git a/lib/cpp/src/reflection_limited_types.cpp b/lib/cpp/src/reflection_limited_types.cpp
new file mode 100644
index 0000000..d5c6153
--- /dev/null
+++ b/lib/cpp/src/reflection_limited_types.cpp
@@ -0,0 +1,489 @@
+/**
+ * Autogenerated by Thrift
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ */
+#include "reflection_limited_types.h"
+
+namespace facebook { namespace thrift { namespace reflection { namespace limited {
+
+uint32_t SimpleType::read(facebook::thrift::protocol::TProtocol* iprot) {
+
+  uint32_t xfer = 0;
+  std::string fname;
+  facebook::thrift::protocol::TType ftype;
+  int16_t fid;
+
+  xfer += iprot->readStructBegin(fname);
+
+  using facebook::thrift::protocol::TProtocolException;
+
+
+  while (true)
+  {
+    xfer += iprot->readFieldBegin(fname, ftype, fid);
+    if (ftype == facebook::thrift::protocol::T_STOP) {
+      break;
+    }
+    switch (fid)
+    {
+      case 1:
+        if (ftype == facebook::thrift::protocol::T_I32) {
+          int32_t ecast0;
+          xfer += iprot->readI32(ecast0);
+          this->ttype = (TTypeTag)ecast0;
+          this->__isset.ttype = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 2:
+        if (ftype == facebook::thrift::protocol::T_STRING) {
+          xfer += iprot->readString(this->name);
+          this->__isset.name = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      default:
+        xfer += iprot->skip(ftype);
+        break;
+    }
+    xfer += iprot->readFieldEnd();
+  }
+
+  xfer += iprot->readStructEnd();
+
+  return xfer;
+}
+
+uint32_t SimpleType::write(facebook::thrift::protocol::TProtocol* oprot) const {
+  uint32_t xfer = 0;
+  xfer += oprot->writeStructBegin("SimpleType");
+  xfer += oprot->writeFieldBegin("ttype", facebook::thrift::protocol::T_I32, 1);
+  xfer += oprot->writeI32((int32_t)this->ttype);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("name", facebook::thrift::protocol::T_STRING, 2);
+  xfer += oprot->writeString(this->name);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldStop();
+  xfer += oprot->writeStructEnd();
+  return xfer;
+}
+
+uint32_t ContainerType::read(facebook::thrift::protocol::TProtocol* iprot) {
+
+  uint32_t xfer = 0;
+  std::string fname;
+  facebook::thrift::protocol::TType ftype;
+  int16_t fid;
+
+  xfer += iprot->readStructBegin(fname);
+
+  using facebook::thrift::protocol::TProtocolException;
+
+
+  while (true)
+  {
+    xfer += iprot->readFieldBegin(fname, ftype, fid);
+    if (ftype == facebook::thrift::protocol::T_STOP) {
+      break;
+    }
+    switch (fid)
+    {
+      case 1:
+        if (ftype == facebook::thrift::protocol::T_I32) {
+          int32_t ecast1;
+          xfer += iprot->readI32(ecast1);
+          this->ttype = (TTypeTag)ecast1;
+          this->__isset.ttype = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 2:
+        if (ftype == facebook::thrift::protocol::T_STRUCT) {
+          xfer += this->subtype1.read(iprot);
+          this->__isset.subtype1 = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 3:
+        if (ftype == facebook::thrift::protocol::T_STRUCT) {
+          xfer += this->subtype2.read(iprot);
+          this->__isset.subtype2 = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      default:
+        xfer += iprot->skip(ftype);
+        break;
+    }
+    xfer += iprot->readFieldEnd();
+  }
+
+  xfer += iprot->readStructEnd();
+
+  return xfer;
+}
+
+uint32_t ContainerType::write(facebook::thrift::protocol::TProtocol* oprot) const {
+  uint32_t xfer = 0;
+  xfer += oprot->writeStructBegin("ContainerType");
+  xfer += oprot->writeFieldBegin("ttype", facebook::thrift::protocol::T_I32, 1);
+  xfer += oprot->writeI32((int32_t)this->ttype);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("subtype1", facebook::thrift::protocol::T_STRUCT, 2);
+  xfer += this->subtype1.write(oprot);
+  xfer += oprot->writeFieldEnd();
+  if (this->__isset.subtype2) {
+    xfer += oprot->writeFieldBegin("subtype2", facebook::thrift::protocol::T_STRUCT, 3);
+    xfer += this->subtype2.write(oprot);
+    xfer += oprot->writeFieldEnd();
+  }
+  xfer += oprot->writeFieldStop();
+  xfer += oprot->writeStructEnd();
+  return xfer;
+}
+
+uint32_t ThriftType::read(facebook::thrift::protocol::TProtocol* iprot) {
+
+  uint32_t xfer = 0;
+  std::string fname;
+  facebook::thrift::protocol::TType ftype;
+  int16_t fid;
+
+  xfer += iprot->readStructBegin(fname);
+
+  using facebook::thrift::protocol::TProtocolException;
+
+
+  while (true)
+  {
+    xfer += iprot->readFieldBegin(fname, ftype, fid);
+    if (ftype == facebook::thrift::protocol::T_STOP) {
+      break;
+    }
+    switch (fid)
+    {
+      case 1:
+        if (ftype == facebook::thrift::protocol::T_BOOL) {
+          xfer += iprot->readBool(this->is_container);
+          this->__isset.is_container = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 2:
+        if (ftype == facebook::thrift::protocol::T_STRUCT) {
+          xfer += this->simple_type.read(iprot);
+          this->__isset.simple_type = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 3:
+        if (ftype == facebook::thrift::protocol::T_STRUCT) {
+          xfer += this->container_type.read(iprot);
+          this->__isset.container_type = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      default:
+        xfer += iprot->skip(ftype);
+        break;
+    }
+    xfer += iprot->readFieldEnd();
+  }
+
+  xfer += iprot->readStructEnd();
+
+  return xfer;
+}
+
+uint32_t ThriftType::write(facebook::thrift::protocol::TProtocol* oprot) const {
+  uint32_t xfer = 0;
+  xfer += oprot->writeStructBegin("ThriftType");
+  xfer += oprot->writeFieldBegin("is_container", facebook::thrift::protocol::T_BOOL, 1);
+  xfer += oprot->writeBool(this->is_container);
+  xfer += oprot->writeFieldEnd();
+  if (this->__isset.simple_type) {
+    xfer += oprot->writeFieldBegin("simple_type", facebook::thrift::protocol::T_STRUCT, 2);
+    xfer += this->simple_type.write(oprot);
+    xfer += oprot->writeFieldEnd();
+  }
+  if (this->__isset.container_type) {
+    xfer += oprot->writeFieldBegin("container_type", facebook::thrift::protocol::T_STRUCT, 3);
+    xfer += this->container_type.write(oprot);
+    xfer += oprot->writeFieldEnd();
+  }
+  xfer += oprot->writeFieldStop();
+  xfer += oprot->writeStructEnd();
+  return xfer;
+}
+
+uint32_t Argument::read(facebook::thrift::protocol::TProtocol* iprot) {
+
+  uint32_t xfer = 0;
+  std::string fname;
+  facebook::thrift::protocol::TType ftype;
+  int16_t fid;
+
+  xfer += iprot->readStructBegin(fname);
+
+  using facebook::thrift::protocol::TProtocolException;
+
+
+  while (true)
+  {
+    xfer += iprot->readFieldBegin(fname, ftype, fid);
+    if (ftype == facebook::thrift::protocol::T_STOP) {
+      break;
+    }
+    switch (fid)
+    {
+      case 1:
+        if (ftype == facebook::thrift::protocol::T_I16) {
+          xfer += iprot->readI16(this->key);
+          this->__isset.key = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 2:
+        if (ftype == facebook::thrift::protocol::T_STRING) {
+          xfer += iprot->readString(this->name);
+          this->__isset.name = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 3:
+        if (ftype == facebook::thrift::protocol::T_STRUCT) {
+          xfer += this->type.read(iprot);
+          this->__isset.type = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      default:
+        xfer += iprot->skip(ftype);
+        break;
+    }
+    xfer += iprot->readFieldEnd();
+  }
+
+  xfer += iprot->readStructEnd();
+
+  return xfer;
+}
+
+uint32_t Argument::write(facebook::thrift::protocol::TProtocol* oprot) const {
+  uint32_t xfer = 0;
+  xfer += oprot->writeStructBegin("Argument");
+  xfer += oprot->writeFieldBegin("key", facebook::thrift::protocol::T_I16, 1);
+  xfer += oprot->writeI16(this->key);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("name", facebook::thrift::protocol::T_STRING, 2);
+  xfer += oprot->writeString(this->name);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("type", facebook::thrift::protocol::T_STRUCT, 3);
+  xfer += this->type.write(oprot);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldStop();
+  xfer += oprot->writeStructEnd();
+  return xfer;
+}
+
+uint32_t Method::read(facebook::thrift::protocol::TProtocol* iprot) {
+
+  uint32_t xfer = 0;
+  std::string fname;
+  facebook::thrift::protocol::TType ftype;
+  int16_t fid;
+
+  xfer += iprot->readStructBegin(fname);
+
+  using facebook::thrift::protocol::TProtocolException;
+
+
+  while (true)
+  {
+    xfer += iprot->readFieldBegin(fname, ftype, fid);
+    if (ftype == facebook::thrift::protocol::T_STOP) {
+      break;
+    }
+    switch (fid)
+    {
+      case 1:
+        if (ftype == facebook::thrift::protocol::T_STRING) {
+          xfer += iprot->readString(this->name);
+          this->__isset.name = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 2:
+        if (ftype == facebook::thrift::protocol::T_STRUCT) {
+          xfer += this->return_type.read(iprot);
+          this->__isset.return_type = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 3:
+        if (ftype == facebook::thrift::protocol::T_LIST) {
+          {
+            this->arguments.clear();
+            uint32_t _size2;
+            facebook::thrift::protocol::TType _etype5;
+            iprot->readListBegin(_etype5, _size2);
+            uint32_t _i6;
+            for (_i6 = 0; _i6 < _size2; ++_i6)
+            {
+              Argument _elem7;
+              xfer += _elem7.read(iprot);
+              this->arguments.push_back(_elem7);
+            }
+            iprot->readListEnd();
+          }
+          this->__isset.arguments = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      default:
+        xfer += iprot->skip(ftype);
+        break;
+    }
+    xfer += iprot->readFieldEnd();
+  }
+
+  xfer += iprot->readStructEnd();
+
+  return xfer;
+}
+
+uint32_t Method::write(facebook::thrift::protocol::TProtocol* oprot) const {
+  uint32_t xfer = 0;
+  xfer += oprot->writeStructBegin("Method");
+  xfer += oprot->writeFieldBegin("name", facebook::thrift::protocol::T_STRING, 1);
+  xfer += oprot->writeString(this->name);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("return_type", facebook::thrift::protocol::T_STRUCT, 2);
+  xfer += this->return_type.write(oprot);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("arguments", facebook::thrift::protocol::T_LIST, 3);
+  {
+    xfer += oprot->writeListBegin(facebook::thrift::protocol::T_STRUCT, this->arguments.size());
+    std::vector<Argument> ::const_iterator _iter8;
+    for (_iter8 = this->arguments.begin(); _iter8 != this->arguments.end(); ++_iter8)
+    {
+      xfer += (*_iter8).write(oprot);
+    }
+    xfer += oprot->writeListEnd();
+  }
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldStop();
+  xfer += oprot->writeStructEnd();
+  return xfer;
+}
+
+uint32_t Service::read(facebook::thrift::protocol::TProtocol* iprot) {
+
+  uint32_t xfer = 0;
+  std::string fname;
+  facebook::thrift::protocol::TType ftype;
+  int16_t fid;
+
+  xfer += iprot->readStructBegin(fname);
+
+  using facebook::thrift::protocol::TProtocolException;
+
+
+  while (true)
+  {
+    xfer += iprot->readFieldBegin(fname, ftype, fid);
+    if (ftype == facebook::thrift::protocol::T_STOP) {
+      break;
+    }
+    switch (fid)
+    {
+      case 1:
+        if (ftype == facebook::thrift::protocol::T_STRING) {
+          xfer += iprot->readString(this->name);
+          this->__isset.name = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 2:
+        if (ftype == facebook::thrift::protocol::T_LIST) {
+          {
+            this->methods.clear();
+            uint32_t _size9;
+            facebook::thrift::protocol::TType _etype12;
+            iprot->readListBegin(_etype12, _size9);
+            uint32_t _i13;
+            for (_i13 = 0; _i13 < _size9; ++_i13)
+            {
+              Method _elem14;
+              xfer += _elem14.read(iprot);
+              this->methods.push_back(_elem14);
+            }
+            iprot->readListEnd();
+          }
+          this->__isset.methods = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      case 3:
+        if (ftype == facebook::thrift::protocol::T_BOOL) {
+          xfer += iprot->readBool(this->fully_reflected);
+          this->__isset.fully_reflected = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
+      default:
+        xfer += iprot->skip(ftype);
+        break;
+    }
+    xfer += iprot->readFieldEnd();
+  }
+
+  xfer += iprot->readStructEnd();
+
+  return xfer;
+}
+
+uint32_t Service::write(facebook::thrift::protocol::TProtocol* oprot) const {
+  uint32_t xfer = 0;
+  xfer += oprot->writeStructBegin("Service");
+  xfer += oprot->writeFieldBegin("name", facebook::thrift::protocol::T_STRING, 1);
+  xfer += oprot->writeString(this->name);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("methods", facebook::thrift::protocol::T_LIST, 2);
+  {
+    xfer += oprot->writeListBegin(facebook::thrift::protocol::T_STRUCT, this->methods.size());
+    std::vector<Method> ::const_iterator _iter15;
+    for (_iter15 = this->methods.begin(); _iter15 != this->methods.end(); ++_iter15)
+    {
+      xfer += (*_iter15).write(oprot);
+    }
+    xfer += oprot->writeListEnd();
+  }
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldBegin("fully_reflected", facebook::thrift::protocol::T_BOOL, 3);
+  xfer += oprot->writeBool(this->fully_reflected);
+  xfer += oprot->writeFieldEnd();
+  xfer += oprot->writeFieldStop();
+  xfer += oprot->writeStructEnd();
+  return xfer;
+}
+
+}}}} // namespace
diff --git a/lib/cpp/src/reflection_limited_types.h b/lib/cpp/src/reflection_limited_types.h
new file mode 100644
index 0000000..843c691
--- /dev/null
+++ b/lib/cpp/src/reflection_limited_types.h
@@ -0,0 +1,266 @@
+/**
+ * Autogenerated by Thrift
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ */
+#ifndef reflection_limited_TYPES_H
+#define reflection_limited_TYPES_H
+
+#include <Thrift.h>
+#include <protocol/TProtocol.h>
+#include <transport/TTransport.h>
+
+
+
+namespace facebook { namespace thrift { namespace reflection { namespace limited {
+
+enum TTypeTag {
+  T_VOID = 1,
+  T_BOOL = 2,
+  T_BYTE = 3,
+  T_I16 = 6,
+  T_I32 = 8,
+  T_I64 = 10,
+  T_DOUBLE = 4,
+  T_STRING = 11,
+  T_STRUCT = 12,
+  T_MAP = 13,
+  T_SET = 14,
+  T_LIST = 15,
+  T_ENUM = 101,
+  T_NOT_REFLECTED = 102
+};
+
+class SimpleType {
+ public:
+
+  SimpleType() : name("") {
+  }
+
+  virtual ~SimpleType() throw() {}
+
+  TTypeTag ttype;
+  std::string name;
+
+  struct __isset {
+    __isset() : ttype(false), name(false) {}
+    bool ttype;
+    bool name;
+  } __isset;
+
+  bool operator == (const SimpleType & rhs) const
+  {
+    if (!(ttype == rhs.ttype))
+      return false;
+    if (!(name == rhs.name))
+      return false;
+    return true;
+  }
+  bool operator != (const SimpleType &rhs) const {
+    return !(*this == rhs);
+  }
+
+  uint32_t read(facebook::thrift::protocol::TProtocol* iprot);
+  uint32_t write(facebook::thrift::protocol::TProtocol* oprot) const;
+
+};
+
+class ContainerType {
+ public:
+
+  ContainerType() {
+  }
+
+  virtual ~ContainerType() throw() {}
+
+  TTypeTag ttype;
+  SimpleType subtype1;
+  SimpleType subtype2;
+
+  struct __isset {
+    __isset() : ttype(false), subtype1(false), subtype2(false) {}
+    bool ttype;
+    bool subtype1;
+    bool subtype2;
+  } __isset;
+
+  bool operator == (const ContainerType & rhs) const
+  {
+    if (!(ttype == rhs.ttype))
+      return false;
+    if (!(subtype1 == rhs.subtype1))
+      return false;
+    if (__isset.subtype2 != rhs.__isset.subtype2)
+      return false;
+    else if (__isset.subtype2 && !(subtype2 == rhs.subtype2))
+      return false;
+    return true;
+  }
+  bool operator != (const ContainerType &rhs) const {
+    return !(*this == rhs);
+  }
+
+  uint32_t read(facebook::thrift::protocol::TProtocol* iprot);
+  uint32_t write(facebook::thrift::protocol::TProtocol* oprot) const;
+
+};
+
+class ThriftType {
+ public:
+
+  ThriftType() : is_container(0) {
+  }
+
+  virtual ~ThriftType() throw() {}
+
+  bool is_container;
+  SimpleType simple_type;
+  ContainerType container_type;
+
+  struct __isset {
+    __isset() : is_container(false), simple_type(false), container_type(false) {}
+    bool is_container;
+    bool simple_type;
+    bool container_type;
+  } __isset;
+
+  bool operator == (const ThriftType & rhs) const
+  {
+    if (!(is_container == rhs.is_container))
+      return false;
+    if (__isset.simple_type != rhs.__isset.simple_type)
+      return false;
+    else if (__isset.simple_type && !(simple_type == rhs.simple_type))
+      return false;
+    if (__isset.container_type != rhs.__isset.container_type)
+      return false;
+    else if (__isset.container_type && !(container_type == rhs.container_type))
+      return false;
+    return true;
+  }
+  bool operator != (const ThriftType &rhs) const {
+    return !(*this == rhs);
+  }
+
+  uint32_t read(facebook::thrift::protocol::TProtocol* iprot);
+  uint32_t write(facebook::thrift::protocol::TProtocol* oprot) const;
+
+};
+
+class Argument {
+ public:
+
+  Argument() : key(0), name("") {
+  }
+
+  virtual ~Argument() throw() {}
+
+  int16_t key;
+  std::string name;
+  ThriftType type;
+
+  struct __isset {
+    __isset() : key(false), name(false), type(false) {}
+    bool key;
+    bool name;
+    bool type;
+  } __isset;
+
+  bool operator == (const Argument & rhs) const
+  {
+    if (!(key == rhs.key))
+      return false;
+    if (!(name == rhs.name))
+      return false;
+    if (!(type == rhs.type))
+      return false;
+    return true;
+  }
+  bool operator != (const Argument &rhs) const {
+    return !(*this == rhs);
+  }
+
+  uint32_t read(facebook::thrift::protocol::TProtocol* iprot);
+  uint32_t write(facebook::thrift::protocol::TProtocol* oprot) const;
+
+};
+
+class Method {
+ public:
+
+  Method() : name("") {
+  }
+
+  virtual ~Method() throw() {}
+
+  std::string name;
+  ThriftType return_type;
+  std::vector<Argument>  arguments;
+
+  struct __isset {
+    __isset() : name(false), return_type(false), arguments(false) {}
+    bool name;
+    bool return_type;
+    bool arguments;
+  } __isset;
+
+  bool operator == (const Method & rhs) const
+  {
+    if (!(name == rhs.name))
+      return false;
+    if (!(return_type == rhs.return_type))
+      return false;
+    if (!(arguments == rhs.arguments))
+      return false;
+    return true;
+  }
+  bool operator != (const Method &rhs) const {
+    return !(*this == rhs);
+  }
+
+  uint32_t read(facebook::thrift::protocol::TProtocol* iprot);
+  uint32_t write(facebook::thrift::protocol::TProtocol* oprot) const;
+
+};
+
+class Service {
+ public:
+
+  Service() : name(""), fully_reflected(0) {
+  }
+
+  virtual ~Service() throw() {}
+
+  std::string name;
+  std::vector<Method>  methods;
+  bool fully_reflected;
+
+  struct __isset {
+    __isset() : name(false), methods(false), fully_reflected(false) {}
+    bool name;
+    bool methods;
+    bool fully_reflected;
+  } __isset;
+
+  bool operator == (const Service & rhs) const
+  {
+    if (!(name == rhs.name))
+      return false;
+    if (!(methods == rhs.methods))
+      return false;
+    if (!(fully_reflected == rhs.fully_reflected))
+      return false;
+    return true;
+  }
+  bool operator != (const Service &rhs) const {
+    return !(*this == rhs);
+  }
+
+  uint32_t read(facebook::thrift::protocol::TProtocol* iprot);
+  uint32_t write(facebook::thrift::protocol::TProtocol* oprot) const;
+
+};
+
+}}}} // namespace
+
+#endif