Fabcoin Core  0.16.2
P2P Digital Currency
Debug.h
Go to the documentation of this file.
1 #pragma once
3 #include "DebugFace.h"
4 
5 namespace dev
6 {
7 
8 namespace eth
9 {
10 class Client;
11 }
12 
13 namespace rpc
14 {
15 
16 class SessionManager;
17 
18 class Debug: public DebugFace
19 {
20 public:
21  explicit Debug(eth::Client const& _eth);
22 
23  virtual RPCModules implementedModules() const override
24  {
25  return RPCModules{RPCModule{"debug", "1.0"}};
26  }
27 
28 
29  virtual Json::Value debug_traceTransaction(std::string const& _txHash, Json::Value const& _json) override;
30  virtual Json::Value debug_traceCall(Json::Value const& _call, std::string const& _blockNumber, Json::Value const& _options) override;
31  virtual Json::Value debug_traceBlockByNumber(int _blockNumber, Json::Value const& _json) override;
32  virtual Json::Value debug_traceBlockByHash(std::string const& _blockHash, Json::Value const& _json) override;
33  virtual Json::Value debug_storageRangeAt(std::string const& _blockHashOrNumber, int _txIndex, std::string const& _address, std::string const& _begin, int _maxResults) override;
34  virtual std::string debug_preimage(std::string const& _hashedKey) override;
35  virtual Json::Value debug_traceBlock(std::string const& _blockRlp, Json::Value const& _json);
36 
37 private:
38 
40  h256 blockHash(std::string const& _blockHashOrNumber) const;
41  Json::Value traceTransaction(dev::eth::Executive& _e, dev::eth::Transaction const& _t, Json::Value const& _json);
42  Json::Value traceBlock(dev::eth::Block const& _block, Json::Value const& _json);
43 };
44 
45 }
46 }
Adapted from code found on http://stackoverflow.com/questions/180947/base64-decode-snippet-in-c Origi...
Definition: Arith256.cpp:15
std::vector< RPCModule > RPCModules
Definition: ModularServer.h:50
virtual RPCModules implementedModules() const override
Definition: Debug.h:23
Active model of a block within the block chain.
Definition: Block.h:73
Config::Value_type Value
Main API hub for interfacing with Ethereum.
Definition: Client.h:75
Message-call/contract-creation executor; useful for executing transactions.
Definition: Executive.h:106
Encodes a transaction, ready to be exported to or freshly imported from RLP.
Definition: Transaction.h:84
eth::Client const & m_eth
Definition: Debug.h:39