![]()  | 
  
    BSHA3
    0.17.99
    
   P2P Blockchain, based on Bitcoin 
   | 
 
#include <rpc/blockchain.h>#include <amount.h>#include <base58.h>#include <chain.h>#include <chainparams.h>#include <checkpoints.h>#include <coins.h>#include <consensus/validation.h>#include <validation.h>#include <core_io.h>#include <index/txindex.h>#include <key_io.h>#include <policy/feerate.h>#include <policy/policy.h>#include <policy/rbf.h>#include <primitives/transaction.h>#include <rpc/server.h>#include <script/descriptor.h>#include <streams.h>#include <sync.h>#include <txdb.h>#include <txmempool.h>#include <util.h>#include <utilstrencodings.h>#include <hash.h>#include <validationinterface.h>#include <versionbitsinfo.h>#include <warnings.h>#include <assert.h>#include <stdint.h>#include <univalue.h>#include <boost/algorithm/string.hpp>#include <boost/thread/thread.hpp>#include <memory>#include <mutex>#include <condition_variable>Go to the source code of this file.
Classes | |
| struct | CUpdatedBlock | 
| struct | CCoinsStats | 
| struct | CompareBlocksByHeight | 
| Comparison function for sorting the getchaintips heads.  More... | |
| class | CoinsViewScanReserver | 
Functions | |
| double | GetDifficulty (const CBlockIndex *blockindex) | 
| Get the difficulty of the net wrt to the given block index.  More... | |
| UniValue | blockheaderToJSON (const CBlockIndex *blockindex) | 
| Block header to JSON.  More... | |
| UniValue | blockToJSON (const CBlock &block, const CBlockIndex *blockindex, bool txDetails) | 
| Block description to JSON.  More... | |
| void | RPCNotifyBlockChange (bool ibd, const CBlockIndex *pindex) | 
| Callback for when block tip changed.  More... | |
| UniValue | mempoolToJSON (bool fVerbose) | 
| Mempool to JSON.  More... | |
| UniValue | gettxout (const JSONRPCRequest &request) | 
| UniValue | getblockchaininfo (const JSONRPCRequest &request) | 
| Implementation of IsSuperMajority with better feedback.  More... | |
| UniValue | mempoolInfoToJSON () | 
| Mempool information to JSON.  More... | |
| void | CalculatePercentilesByWeight (CAmount result[NUM_GETBLOCKSTATS_PERCENTILES], std::vector< std::pair< CAmount, int64_t >> &scores, int64_t total_weight) | 
| Used by getblockstats to get feerates at different percentiles by weight.  More... | |
| bool | FindScriptPubKey (std::atomic< int > &scan_progress, const std::atomic< bool > &should_abort, int64_t &count, CCoinsViewCursor *cursor, const std::set< CScript > &needles, std::map< COutPoint, Coin > &out_results) | 
| Search for a given set of pubkey scripts.  More... | |
| UniValue | scantxoutset (const JSONRPCRequest &request) | 
| void | RegisterBlockchainRPCCommands (CRPCTable &t) | 
| Register block chain RPC commands.  More... | |
| UniValue blockheaderToJSON | ( | const CBlockIndex * | blockindex | ) | 
Block header to JSON.
Definition at line 88 of file blockchain.cpp.
| UniValue blockToJSON | ( | const CBlock & | block, | 
| const CBlockIndex * | blockindex, | ||
| bool | txDetails | ||
| ) | 
Block description to JSON.
Definition at line 118 of file blockchain.cpp.
| void CalculatePercentilesByWeight | ( | CAmount | result[NUM_GETBLOCKSTATS_PERCENTILES], | 
| std::vector< std::pair< CAmount, int64_t >> & | scores, | ||
| int64_t | total_weight | ||
| ) | 
Used by getblockstats to get feerates at different percentiles by weight.
Definition at line 1662 of file blockchain.cpp.
| bool FindScriptPubKey | ( | std::atomic< int > & | scan_progress, | 
| const std::atomic< bool > & | should_abort, | ||
| int64_t & | count, | ||
| CCoinsViewCursor * | cursor, | ||
| const std::set< CScript > & | needles, | ||
| std::map< COutPoint, Coin > & | out_results | ||
| ) | 
Search for a given set of pubkey scripts.
Definition at line 1990 of file blockchain.cpp.
| UniValue getblockchaininfo | ( | const JSONRPCRequest & | request | ) | 
Implementation of IsSuperMajority with better feedback.
Definition at line 1201 of file blockchain.cpp.
| double GetDifficulty | ( | const CBlockIndex * | blockindex | ) | 
Get the difficulty of the net wrt to the given block index.
Definition at line 60 of file blockchain.cpp.
| UniValue gettxout | ( | const JSONRPCRequest & | request | ) | 
| UniValue mempoolInfoToJSON | ( | ) | 
Mempool information to JSON.
Definition at line 1423 of file blockchain.cpp.
| UniValue mempoolToJSON | ( | bool | fVerbose | ) | 
Mempool to JSON.
Definition at line 451 of file blockchain.cpp.
| void RegisterBlockchainRPCCommands | ( | CRPCTable & | t | ) | 
Register block chain RPC commands.
Definition at line 2238 of file blockchain.cpp.
| void RPCNotifyBlockChange | ( | bool | ibd, | 
| const CBlockIndex * | |||
| ) | 
Callback for when block tip changed.
Definition at line 198 of file blockchain.cpp.
| UniValue scantxoutset | ( | const JSONRPCRequest & | request | ) | 
 1.8.14