Simplify difficulty calculation API
This commit is contained in:
parent
90f580ff64
commit
e016663524
4 changed files with 14 additions and 30 deletions
|
|
@ -29,12 +29,12 @@ struct NodeContext;
|
|||
static constexpr int NUM_GETBLOCKSTATS_PERCENTILES = 5;
|
||||
|
||||
/**
|
||||
* Get the difficulty of the net wrt to the given block index.
|
||||
* Get the difficulty represented by the given block index nBits.
|
||||
*
|
||||
* @return A floating point number that is a multiple of the main net minimum
|
||||
* difficulty (4295032833 hashes).
|
||||
*/
|
||||
double GetDifficulty(const CBlockIndex* tip = NULL, const CBlockIndex* blockindex = nullptr);
|
||||
double GetDifficulty(const CBlockIndex* blockindex);
|
||||
|
||||
/** Callback for when block tip changed. */
|
||||
void RPCNotifyBlockChange(const CBlockIndex*);
|
||||
|
|
|
|||
Loading…
Reference in a new issue