identt
HrpcClient.hpp
Go to the documentation of this file.
1 
33 #ifndef _IDENTT_HRPC_HRPC_CLIENT_HPP_
34 #define _IDENTT_HRPC_HRPC_CLIENT_HPP_
35 
36 #include "utils/BaseUtils.hpp"
37 #include "utils/SharedTable.hpp"
38 #include <google/protobuf/message.h>
39 #include "../proto/Hrpc.pb.h"
40 
41 #include "query/bin2ascii.h"
42 
43 namespace identt {
44 namespace hrpc {
45 
46 class HrpcClient {
47 public:
52  HrpcClient();
53 
57  HrpcClient(const HrpcClient&) = delete;
58  HrpcClient& operator=(const HrpcClient&) = delete;
59 
63  virtual ~HrpcClient ();
64 
83  bool SendToMaster(::identt::utils::SharedTable::pointer stptr, ::identt::hrpc::MasterCmdTypeE service_id,
84  google::protobuf::Message* msg, bool nothrow=false);
85 
107  bool SendToRemote(::identt::utils::SharedTable::pointer stptr, std::string address,
108  ::identt::hrpc::RemoteCmdTypeE service_id, google::protobuf::Message* msg, bool nothrow=false);
109 
110 };
111 } // namespace hrpc
112 } // namespace identt
113 #endif // _IDENTT_HRPC_HRPC_CLIENT_HPP_
114 
HrpcClient()
constructor
Definition: HrpcClient.cc:47
Definition: CryptoBase.hpp:49
bool SendToRemote(::identt::utils::SharedTable::pointer stptr, std::string address, ::identt::hrpc::RemoteCmdTypeE service_id, google::protobuf::Message *msg, bool nothrow=false)
SendToRemote : send to remote and get output.
virtual ~HrpcClient()
destructor
Definition: HrpcClient.cc:52
Definition: HrpcClient.hpp:46
bool SendToMaster(::identt::utils::SharedTable::pointer stptr, ::identt::hrpc::MasterCmdTypeE service_id, google::protobuf::Message *msg, bool nothrow=false)
SendToMaster : send to master and get output.