hdac SDK
SDK for hdac blockchain development
hs_rpc.h
1 
2 #ifndef HS_RPC_H
3 #define HS_RPC_H
4 
5 #include <json_spirit/json_spirit.h>
6 
7 class RpcClient;
8 
10 json_spirit::Object getinfo(const RpcClient& client);
11 
13 json_spirit::Object blockChainParams(const RpcClient& client);
14 
16 json_spirit::Object listunspent(const RpcClient& client, int minConf = 1, int maxConf = 9999999,
17  const std::vector<std::string>& addresses = std::vector<std::string>{});
18 
20 json_spirit::Object listunspent(const RpcClient& client, const std::vector<std::string>& addresses);
21 
23 json_spirit::Object listunspent(const RpcClient& client, const std::string& address);
24 
26 json_spirit::Object lockunspent(const RpcClient& client, bool unlock, std::string txid, int vout);
27 
29 json_spirit::Object listlockunspent(const RpcClient& client);
30 
32 json_spirit::Object liststreams(const RpcClient& client, const std::vector<std::string> &streamNames);
33 
35 json_spirit::Object liststreams(const RpcClient& client, const std::string &streamName = "all");
36 
38 json_spirit::Object listassets(const RpcClient& client, const std::vector<std::string> &assetNames);
39 
41 json_spirit::Object listassets(const RpcClient& client, const std::string &name = "");
42 
44 json_spirit::Object verifymessage(const RpcClient& client,
45  const std::string &strAddress,
46  const std::string &strSignmessage,
47  const std::string &strText);
48 
50 json_spirit::Object signmessage(const RpcClient& client,
51  const std::string &strPrivateKey,
52  const std::string &strText);
53 
55 json_spirit::Object importaddress(const RpcClient& client, const std::string &address, bool rescan = true);
56 
58 json_spirit::Object importaddress(const RpcClient& client, const std::vector<std::string>& addresses, bool rescan = true);
59 
61 json_spirit::Object sendrawtx(const RpcClient& client, const std::string& rawTx);
62 
64 bool rpcResult(const json_spirit::Object& reply, std::string &resultStr);
65 
66 #endif // HS_RPC_H
Object blockChainParams(const RpcClient &client)
RPC 명령어를 통하여 HDAC 네트워크의 파라미터 설정 정보를 가져 온다.
Definition: hs_rpc.cpp:106
Object listlockunspent(const RpcClient &client)
RPC 명령어를 통하여 아직 보내지 못한 transaction 들 중에 잠겨 있는 transaction 들의 정보를 가져 온다...
Definition: hs_rpc.cpp:218
Object sendrawtx(const RpcClient &client, const string &rawTx)
RPC 명령어를 통하여 createrawtx 를 통하여 만들어진 rawtransaction 을 전송 한다.
Definition: hs_rpc.cpp:30
Definition: rpcclient.h:18
Object signmessage(const RpcClient &client, const string &strPrivateKey, const string &strText)
RPC 명령어를 통하여 개인키를 이용 하여 sign 된 메시지를 만든다.
Definition: hs_rpc.cpp:314
Object getinfo(const RpcClient &client)
RPC 명령어를 통하여 HDAC 네트워크의 기본 정보를 가져 온다.
Definition: hs_rpc.cpp:90
Object liststreams(const RpcClient &client, const vector< string > &streamNames)
RPC 명령어를 통하여 생성 된 stream 들의 정보를 가져 온다.
Definition: hs_rpc.cpp:233
Object importaddress(const RpcClient &client, const string &address, bool rescan)
RPC 명령어를 통하여 특정 주소의 정보를 가져 온다.
Definition: hs_rpc.cpp:49
Object verifymessage(const RpcClient &client, const string &strAddress, const string &strSignmessage, const string &strText)
RPC 명령어를 통하여 sign 된 메시지를 검증 한다.
Definition: hs_rpc.cpp:340
Object lockunspent(const RpcClient &client, bool unlock, string txid, int vout)
RPC 명령어를 통하여 아직 보내지 못한 transaction 을 잠금 하거나 또는 잠금 해제 할 수 있게 한다...
Definition: hs_rpc.cpp:195
bool rpcResult(const Object &reply, string &resultStr)
json 형태의 RPC 명령어 결과를 string 형으로 변환 시켜 준다.
Definition: hs_rpc.cpp:368
Object listunspent(const RpcClient &client, int minConf, int maxConf, const vector< string > &addresses)
RPC 명령어를 통하여 아직 보내지 못한 transaction 들의 정보를 가져 온다.
Definition: hs_rpc.cpp:123
Object listassets(const RpcClient &client, const vector< string > &assetNames)
RPC 명령어를 통하여 정의 된 asset 들의 정보를 가져 온다.
Definition: hs_rpc.cpp:271