forked from bcosorg/bcos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
TestFace.h
53 lines (48 loc) · 2.95 KB
/
TestFace.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
/**
* This file is generated by jsonrpcstub, DO NOT CHANGE IT MANUALLY!
*/
#ifndef JSONRPC_CPP_STUB_DEV_RPC_TESTFACE_H_
#define JSONRPC_CPP_STUB_DEV_RPC_TESTFACE_H_
#include "ModularServer.h"
namespace dev {
namespace rpc {
class TestFace : public ServerInterface<TestFace>
{
public:
TestFace()
{
this->bindAndAddMethod(jsonrpc::Procedure("test_setChainParams", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_OBJECT, NULL), &dev::rpc::TestFace::test_setChainParamsI);
this->bindAndAddMethod(jsonrpc::Procedure("test_mineBlocks", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_INTEGER, NULL), &dev::rpc::TestFace::test_mineBlocksI);
this->bindAndAddMethod(jsonrpc::Procedure("test_modifyTimestamp", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_INTEGER, NULL), &dev::rpc::TestFace::test_modifyTimestampI);
this->bindAndAddMethod(jsonrpc::Procedure("test_addBlock", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_STRING, NULL), &dev::rpc::TestFace::test_addBlockI);
this->bindAndAddMethod(jsonrpc::Procedure("test_rewindToBlock", jsonrpc::PARAMS_BY_POSITION, jsonrpc::JSON_BOOLEAN, "param1",jsonrpc::JSON_INTEGER, NULL), &dev::rpc::TestFace::test_rewindToBlockI);
}
inline virtual void test_setChainParamsI(const Json::Value &request, Json::Value &response)
{
response = this->test_setChainParams(request[0u]);
}
inline virtual void test_mineBlocksI(const Json::Value &request, Json::Value &response)
{
response = this->test_mineBlocks(request[0u].asInt());
}
inline virtual void test_modifyTimestampI(const Json::Value &request, Json::Value &response)
{
response = this->test_modifyTimestamp(request[0u].asInt());
}
inline virtual void test_addBlockI(const Json::Value &request, Json::Value &response)
{
response = this->test_addBlock(request[0u].asString());
}
inline virtual void test_rewindToBlockI(const Json::Value &request, Json::Value &response)
{
response = this->test_rewindToBlock(request[0u].asInt());
}
virtual bool test_setChainParams(const Json::Value& param1) = 0;
virtual bool test_mineBlocks(int param1) = 0;
virtual bool test_modifyTimestamp(int param1) = 0;
virtual bool test_addBlock(const std::string& param1) = 0;
virtual bool test_rewindToBlock(int param1) = 0;
};
}
}
#endif //JSONRPC_CPP_STUB_DEV_RPC_TESTFACE_H_