forked from bcosorg/bcos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
AdminNetFace.h
104 lines (94 loc) · 6.29 KB
/
AdminNetFace.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
/**
* This file is generated by jsonrpcstub, DO NOT CHANGE IT MANUALLY!
*/
#ifndef JSONRPC_CPP_STUB_DEV_RPC_ADMINNETFACE_H_
#define JSONRPC_CPP_STUB_DEV_RPC_ADMINNETFACE_H_
#include "ModularServer.h"
namespace dev {
namespace rpc {
class AdminNetFace : public ServerInterface<AdminNetFace>
{
public:
AdminNetFace()
{
this->bindAndAddMethod(jsonrpc::Procedure("admin_net_start", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_net_startI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_net_stop", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_net_stopI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_net_connect", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_STRING,"param2",jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_net_connectI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_net_peers", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_ARRAY, "param1",jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_net_peersI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_net_nodeInfo", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_OBJECT, "param1",jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_net_nodeInfoI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_nodeInfo", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_OBJECT, NULL), &dev::rpc::AdminNetFace::admin_nodeInfoI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_peers", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_OBJECT, NULL), &dev::rpc::AdminNetFace::admin_peersI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_addPeer", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_addPeerI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_NodePubKeyInfos", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_OBJECT, NULL), &dev::rpc::AdminNetFace::admin_NodePubKeyInfosI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_ConfNodePubKeyInfos", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_OBJECT, NULL), &dev::rpc::AdminNetFace::admin_ConfNodePubKeyInfosI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_addNodePubKeyInfo", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1", jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_addNodePubKeyInfoI);
this->bindAndAddMethod(jsonrpc::Procedure("admin_delNodePubKeyInfo", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1", jsonrpc::JSON_STRING, NULL), &dev::rpc::AdminNetFace::admin_delNodePubKeyInfoI);
}
inline virtual void admin_net_startI(const Json::Value &request, Json::Value &response)
{
response = this->admin_net_start(request[0u].asString());
}
inline virtual void admin_net_stopI(const Json::Value &request, Json::Value &response)
{
response = this->admin_net_stop(request[0u].asString());
}
inline virtual void admin_net_connectI(const Json::Value &request, Json::Value &response)
{
response = this->admin_net_connect(request[0u].asString(), request[1u].asString());
}
inline virtual void admin_net_peersI(const Json::Value &request, Json::Value &response)
{
response = this->admin_net_peers(request[0u].asString());
}
inline virtual void admin_net_nodeInfoI(const Json::Value &request, Json::Value &response)
{
response = this->admin_net_nodeInfo(request[0u].asString());
}
inline virtual void admin_nodeInfoI(const Json::Value &request, Json::Value &response)
{
(void)request;
response = this->admin_nodeInfo();
}
inline virtual void admin_peersI(const Json::Value &request, Json::Value &response)
{
(void)request;
response = this->admin_peers();
}
inline virtual void admin_addPeerI(const Json::Value &request, Json::Value &response)
{
response = this->admin_addPeer(request[0u].asString());
}
inline virtual void admin_addNodePubKeyInfoI(const Json::Value &request, Json::Value &response)
{
response = this->admin_addNodePubKeyInfo(request[0u].asString());
}
inline virtual void admin_delNodePubKeyInfoI(const Json::Value &request, Json::Value &response)
{
response = this->admin_delNodePubKeyInfo(request[0u].asString());
}
inline virtual void admin_NodePubKeyInfosI(const Json::Value &request, Json::Value &response)
{
(void)request;
response = this->admin_NodePubKeyInfos();
}
inline virtual void admin_ConfNodePubKeyInfosI(const Json::Value &request, Json::Value &response)
{
(void)request;
response = this->admin_ConfNodePubKeyInfos();
}
virtual bool admin_net_start(const std::string& param1) = 0;
virtual bool admin_net_stop(const std::string& param1) = 0;
virtual bool admin_net_connect(const std::string& param1, const std::string& param2) = 0;
virtual Json::Value admin_net_peers(const std::string& param1) = 0;
virtual Json::Value admin_net_nodeInfo(const std::string& param1) = 0;
virtual Json::Value admin_nodeInfo() = 0;
virtual Json::Value admin_peers() = 0;
virtual bool admin_addPeer(const std::string& param1) = 0;
virtual bool admin_addNodePubKeyInfo(const std::string& param1) = 0;
virtual bool admin_delNodePubKeyInfo(const std::string& param1) = 0;
virtual Json::Value admin_NodePubKeyInfos() = 0;
virtual Json::Value admin_ConfNodePubKeyInfos() = 0;
};
}
}
#endif //JSONRPC_CPP_STUB_DEV_RPC_ADMINNETFACE_H_