text: /**
   * Autogenerated by Thrift Compiler (0.12.0)
   *
   * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
   *  @generated
   */
  #ifndef CastInfoService_H
  #define CastInfoService_H
  
  #include <thrift/TDispatchProcessor.h>
  #include <thrift/async/TConcurrentClientSyncInfo.h>
  #include "media_service_types.h"
  
  namespace media_service {
  
  #ifdef _MSC_VER
    #pragma warning( push )
    #pragma warning (disable : 4250 ) //inheriting methods via dominance 
  #endif
  
  class CastInfoServiceIf {
   public:
    virtual ~CastInfoServiceIf() {}
    virtual void WriteCastInfo(const int64_t req_id, const int64_t cast_info_id, const std::string& name, const bool gender, const std::string& intro, const std::map<std::string, std::string> & carrier) = 0;
    virtual void ReadCastInfo(std::vector<CastInfo> & _return, const int64_t req_id, const std::vector<int64_t> & cast_ids, const std::map<std::string, std::string> & carrier) = 0;
  };
  
  class CastInfoServiceIfFactory {
   public:
    typedef CastInfoServiceIf Handler;
  
    virtual ~CastInfoServiceIfFactory() {}
  
    virtual CastInfoServiceIf* getHandler(const ::apache::thrift::TConnectionInfo& connInfo) = 0;
    virtual void releaseHandler(CastInfoServiceIf* /* handler */) = 0;
  };
  
  class CastInfoServiceIfSingletonFactory : virtual public CastInfoServiceIfFactory {
   public:
    CastInfoServiceIfSingletonFactory(const ::apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf>& iface) : iface_(iface) {}
    virtual ~CastInfoServiceIfSingletonFactory() {}
  
    virtual CastInfoServiceIf* getHandler(const ::apache::thrift::TConnectionInfo&) {
      return iface_.get();
    }
    virtual void releaseHandler(CastInfoServiceIf* /* handler */) {}
  
   protected:
    ::apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf> iface_;
  };
  
  class CastInfoServiceNull : virtual public CastInfoServiceIf {
   public:
    virtual ~CastInfoServiceNull() {}
    void WriteCastInfo(const int64_t /* req_id */, const int64_t /* cast_info_id */, const std::string& /* name */, const bool /* gender */, const std::string& /* intro */, const std::map<std::string, std::string> & /* carrier */) {
      return;
    }
    void ReadCastInfo(std::vector<CastInfo> & /* _return */, const int64_t /* req_id */, const std::vector<int64_t> & /* cast_ids */, const std::map<std::string, std::string> & /* carrier */) {
      return;
    }
  };
  
  typedef struct _CastInfoService_WriteCastInfo_args__isset {
    _CastInfoService_WriteCastInfo_args__isset() : req_id(false), cast_info_id(false), name(false), gender(false), intro(false), carrier(false) {}
    bool req_id :1;
    bool cast_info_id :1;
    bool name :1;
    bool gender :1;
    bool intro :1;
    bool carrier :1;
  } _CastInfoService_WriteCastInfo_args__isset;
  
  class CastInfoService_WriteCastInfo_args {
   public:
  
    CastInfoService_WriteCastInfo_args(const CastInfoService_WriteCastInfo_args&);
    CastInfoService_WriteCastInfo_args& operator=(const CastInfoService_WriteCastInfo_args&);
    CastInfoService_WriteCastInfo_args() : req_id(0), cast_info_id(0), name(), gender(0), intro() {
    }
  
    virtual ~CastInfoService_WriteCastInfo_args() throw();
    int64_t req_id;
    int64_t cast_info_id;
    std::string name;
    bool gender;
    std::string intro;
    std::map<std::string, std::string>  carrier;
  
    _CastInfoService_WriteCastInfo_args__isset __isset;
  
    void __set_req_id(const int64_t val);
  
    void __set_cast_info_id(const int64_t val);
  
    void __set_name(const std::string& val);
  
    void __set_gender(const bool val);
  
    void __set_intro(const std::string& val);
  
    void __set_carrier(const std::map<std::string, std::string> & val);
  
    bool operator == (const CastInfoService_WriteCastInfo_args & rhs) const
    {
      if (!(req_id == rhs.req_id))
        return false;
      if (!(cast_info_id == rhs.cast_info_id))
        return false;
      if (!(name == rhs.name))
        return false;
      if (!(gender == rhs.gender))
        return false;
      if (!(intro == rhs.intro))
        return false;
      if (!(carrier == rhs.carrier))
        return false;
      return true;
    }
    bool operator != (const CastInfoService_WriteCastInfo_args &rhs) const {
      return !(*this == rhs);
    }
  
    bool operator < (const CastInfoService_WriteCastInfo_args & ) const;
  
    uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
    uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
  
  };
  
  
  class CastInfoService_WriteCastInfo_pargs {
   public:
  
  
    virtual ~CastInfoService_WriteCastInfo_pargs() throw();
    const int64_t* req_id;
    const int64_t* cast_info_id;
    const std::string* name;
    const bool* gender;
    const std::string* intro;
    const std::map<std::string, std::string> * carrier;
  
    uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
  
  };
  
  typedef struct _CastInfoService_WriteCastInfo_result__isset {
    _CastInfoService_WriteCastInfo_result__isset() : se(false) {}
    bool se :1;
  } _CastInfoService_WriteCastInfo_result__isset;
  
  class CastInfoService_WriteCastInfo_result {
   public:
  
    CastInfoService_WriteCastInfo_result(const CastInfoService_WriteCastInfo_result&);
    CastInfoService_WriteCastInfo_result& operator=(const CastInfoService_WriteCastInfo_result&);
    CastInfoService_WriteCastInfo_result() {
    }
  
    virtual ~CastInfoService_WriteCastInfo_result() throw();
    ServiceException se;
  
    _CastInfoService_WriteCastInfo_result__isset __isset;
  
    void __set_se(const ServiceException& val);
  
    bool operator == (const CastInfoService_WriteCastInfo_result & rhs) const
    {
      if (!(se == rhs.se))
        return false;
      return true;
    }
    bool operator != (const CastInfoService_WriteCastInfo_result &rhs) const {
      return !(*this == rhs);
    }
  
    bool operator < (const CastInfoService_WriteCastInfo_result & ) const;
  
    uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
    uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
  
  };
  
  typedef struct _CastInfoService_WriteCastInfo_presult__isset {
    _CastInfoService_WriteCastInfo_presult__isset() : se(false) {}
    bool se :1;
  } _CastInfoService_WriteCastInfo_presult__isset;
  
  class CastInfoService_WriteCastInfo_presult {
   public:
  
  
    virtual ~CastInfoService_WriteCastInfo_presult() throw();
    ServiceException se;
  
    _CastInfoService_WriteCastInfo_presult__isset __isset;
  
    uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
  
  };
  
  typedef struct _CastInfoService_ReadCastInfo_args__isset {
    _CastInfoService_ReadCastInfo_args__isset() : req_id(false), cast_ids(false), carrier(false) {}
    bool req_id :1;
    bool cast_ids :1;
    bool carrier :1;
  } _CastInfoService_ReadCastInfo_args__isset;
  
  class CastInfoService_ReadCastInfo_args {
   public:
  
    CastInfoService_ReadCastInfo_args(const CastInfoService_ReadCastInfo_args&);
    CastInfoService_ReadCastInfo_args& operator=(const CastInfoService_ReadCastInfo_args&);
    CastInfoService_ReadCastInfo_args() : req_id(0) {
    }
  
    virtual ~CastInfoService_ReadCastInfo_args() throw();
    int64_t req_id;
    std::vector<int64_t>  cast_ids;
    std::map<std::string, std::string>  carrier;
  
    _CastInfoService_ReadCastInfo_args__isset __isset;
  
    void __set_req_id(const int64_t val);
  
    void __set_cast_ids(const std::vector<int64_t> & val);
  
    void __set_carrier(const std::map<std::string, std::string> & val);
  
    bool operator == (const CastInfoService_ReadCastInfo_args & rhs) const
    {
      if (!(req_id == rhs.req_id))
        return false;
      if (!(cast_ids == rhs.cast_ids))
        return false;
      if (!(carrier == rhs.carrier))
        return false;
      return true;
    }
    bool operator != (const CastInfoService_ReadCastInfo_args &rhs) const {
      return !(*this == rhs);
    }
  
    bool operator < (const CastInfoService_ReadCastInfo_args & ) const;
  
    uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
    uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
  
  };
  
  
  class CastInfoService_ReadCastInfo_pargs {
   public:
  
  
    virtual ~CastInfoService_ReadCastInfo_pargs() throw();
    const int64_t* req_id;
    const std::vector<int64_t> * cast_ids;
    const std::map<std::string, std::string> * carrier;
  
    uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
  
  };
  
  typedef struct _CastInfoService_ReadCastInfo_result__isset {
    _CastInfoService_ReadCastInfo_result__isset() : success(false), se(false) {}
    bool success :1;
    bool se :1;
  } _CastInfoService_ReadCastInfo_result__isset;
  
  class CastInfoService_ReadCastInfo_result {
   public:
  
    CastInfoService_ReadCastInfo_result(const CastInfoService_ReadCastInfo_result&);
    CastInfoService_ReadCastInfo_result& operator=(const CastInfoService_ReadCastInfo_result&);
    CastInfoService_ReadCastInfo_result() {
    }
  
    virtual ~CastInfoService_ReadCastInfo_result() throw();
    std::vector<CastInfo>  success;
    ServiceException se;
  
    _CastInfoService_ReadCastInfo_result__isset __isset;
  
    void __set_success(const std::vector<CastInfo> & val);
  
    void __set_se(const ServiceException& val);
  
    bool operator == (const CastInfoService_ReadCastInfo_result & rhs) const
    {
      if (!(success == rhs.success))
        return false;
      if (!(se == rhs.se))
        return false;
      return true;
    }
    bool operator != (const CastInfoService_ReadCastInfo_result &rhs) const {
      return !(*this == rhs);
    }
  
    bool operator < (const CastInfoService_ReadCastInfo_result & ) const;
  
    uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
    uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
  
  };
  
  typedef struct _CastInfoService_ReadCastInfo_presult__isset {
    _CastInfoService_ReadCastInfo_presult__isset() : success(false), se(false) {}
    bool success :1;
    bool se :1;
  } _CastInfoService_ReadCastInfo_presult__isset;
  
  class CastInfoService_ReadCastInfo_presult {
   public:
  
  
    virtual ~CastInfoService_ReadCastInfo_presult() throw();
    std::vector<CastInfo> * success;
    ServiceException se;
  
    _CastInfoService_ReadCastInfo_presult__isset __isset;
  
    uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
  
  };
  
  class CastInfoServiceClient : virtual public CastInfoServiceIf {
   public:
    CastInfoServiceClient(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> prot) {
      setProtocol(prot);
    }
    CastInfoServiceClient(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> iprot, apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> oprot) {
      setProtocol(iprot,oprot);
    }
   private:
    void setProtocol(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> prot) {
    setProtocol(prot,prot);
    }
    void setProtocol(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> iprot, apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> oprot) {
      piprot_=iprot;
      poprot_=oprot;
      iprot_ = iprot.get();
      oprot_ = oprot.get();
    }
   public:
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> getInputProtocol() {
      return piprot_;
    }
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> getOutputProtocol() {
      return poprot_;
    }
    void WriteCastInfo(const int64_t req_id, const int64_t cast_info_id, const std::string& name, const bool gender, const std::string& intro, const std::map<std::string, std::string> & carrier);
    void send_WriteCastInfo(const int64_t req_id, const int64_t cast_info_id, const std::string& name, const bool gender, const std::string& intro, const std::map<std::string, std::string> & carrier);
    void recv_WriteCastInfo();
    void ReadCastInfo(std::vector<CastInfo> & _return, const int64_t req_id, const std::vector<int64_t> & cast_ids, const std::map<std::string, std::string> & carrier);
    void send_ReadCastInfo(const int64_t req_id, const std::vector<int64_t> & cast_ids, const std::map<std::string, std::string> & carrier);
    void recv_ReadCastInfo(std::vector<CastInfo> & _return);
   protected:
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> piprot_;
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> poprot_;
    ::apache::thrift::protocol::TProtocol* iprot_;
    ::apache::thrift::protocol::TProtocol* oprot_;
  };
  
  class CastInfoServiceProcessor : public ::apache::thrift::TDispatchProcessor {
   protected:
    ::apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf> iface_;
    virtual bool dispatchCall(::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, const std::string& fname, int32_t seqid, void* callContext);
   private:
    typedef  void (CastInfoServiceProcessor::*ProcessFunction)(int32_t, ::apache::thrift::protocol::TProtocol*, ::apache::thrift::protocol::TProtocol*, void*);
    typedef std::map<std::string, ProcessFunction> ProcessMap;
    ProcessMap processMap_;
    void process_WriteCastInfo(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
    void process_ReadCastInfo(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
   public:
    CastInfoServiceProcessor(::apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf> iface) :
      iface_(iface) {
      processMap_["WriteCastInfo"] = &CastInfoServiceProcessor::process_WriteCastInfo;
      processMap_["ReadCastInfo"] = &CastInfoServiceProcessor::process_ReadCastInfo;
    }
  
    virtual ~CastInfoServiceProcessor() {}
  };
  
  class CastInfoServiceProcessorFactory : public ::apache::thrift::TProcessorFactory {
   public:
    CastInfoServiceProcessorFactory(const ::apache::thrift::stdcxx::shared_ptr< CastInfoServiceIfFactory >& handlerFactory) :
        handlerFactory_(handlerFactory) {}
  
    ::apache::thrift::stdcxx::shared_ptr< ::apache::thrift::TProcessor > getProcessor(const ::apache::thrift::TConnectionInfo& connInfo);
  
   protected:
    ::apache::thrift::stdcxx::shared_ptr< CastInfoServiceIfFactory > handlerFactory_;
  };
  
  class CastInfoServiceMultiface : virtual public CastInfoServiceIf {
   public:
    CastInfoServiceMultiface(std::vector<apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf> >& ifaces) : ifaces_(ifaces) {
    }
    virtual ~CastInfoServiceMultiface() {}
   protected:
    std::vector<apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf> > ifaces_;
    CastInfoServiceMultiface() {}
    void add(::apache::thrift::stdcxx::shared_ptr<CastInfoServiceIf> iface) {
      ifaces_.push_back(iface);
    }
   public:
    void WriteCastInfo(const int64_t req_id, const int64_t cast_info_id, const std::string& name, const bool gender, const std::string& intro, const std::map<std::string, std::string> & carrier) {
      size_t sz = ifaces_.size();
      size_t i = 0;
      for (; i < (sz - 1); ++i) {
        ifaces_[i]->WriteCastInfo(req_id, cast_info_id, name, gender, intro, carrier);
      }
      ifaces_[i]->WriteCastInfo(req_id, cast_info_id, name, gender, intro, carrier);
    }
  
    void ReadCastInfo(std::vector<CastInfo> & _return, const int64_t req_id, const std::vector<int64_t> & cast_ids, const std::map<std::string, std::string> & carrier) {
      size_t sz = ifaces_.size();
      size_t i = 0;
      for (; i < (sz - 1); ++i) {
        ifaces_[i]->ReadCastInfo(_return, req_id, cast_ids, carrier);
      }
      ifaces_[i]->ReadCastInfo(_return, req_id, cast_ids, carrier);
      return;
    }
  
  };
  
  // The 'concurrent' client is a thread safe client that correctly handles
  // out of order responses.  It is slower than the regular client, so should
  // only be used when you need to share a connection among multiple threads
  class CastInfoServiceConcurrentClient : virtual public CastInfoServiceIf {
   public:
    CastInfoServiceConcurrentClient(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> prot) {
      setProtocol(prot);
    }
    CastInfoServiceConcurrentClient(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> iprot, apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> oprot) {
      setProtocol(iprot,oprot);
    }
   private:
    void setProtocol(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> prot) {
    setProtocol(prot,prot);
    }
    void setProtocol(apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> iprot, apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> oprot) {
      piprot_=iprot;
      poprot_=oprot;
      iprot_ = iprot.get();
      oprot_ = oprot.get();
    }
   public:
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> getInputProtocol() {
      return piprot_;
    }
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> getOutputProtocol() {
      return poprot_;
    }
    void WriteCastInfo(const int64_t req_id, const int64_t cast_info_id, const std::string& name, const bool gender, const std::string& intro, const std::map<std::string, std::string> & carrier);
    int32_t send_WriteCastInfo(const int64_t req_id, const int64_t cast_info_id, const std::string& name, const bool gender, const std::string& intro, const std::map<std::string, std::string> & carrier);
    void recv_WriteCastInfo(const int32_t seqid);
    void ReadCastInfo(std::vector<CastInfo> & _return, const int64_t req_id, const std::vector<int64_t> & cast_ids, const std::map<std::string, std::string> & carrier);
    int32_t send_ReadCastInfo(const int64_t req_id, const std::vector<int64_t> & cast_ids, const std::map<std::string, std::string> & carrier);
    void recv_ReadCastInfo(std::vector<CastInfo> & _return, const int32_t seqid);
   protected:
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> piprot_;
    apache::thrift::stdcxx::shared_ptr< ::apache::thrift::protocol::TProtocol> poprot_;
    ::apache::thrift::protocol::TProtocol* iprot_;
    ::apache::thrift::protocol::TProtocol* oprot_;
    ::apache::thrift::async::TConcurrentClientSyncInfo sync_;
  };
  
  #ifdef _MSC_VER
    #pragma warning( pop )
  #endif
  
  } // namespace
  
  #endif
  