Bitcoin ABC  0.22.13
P2P Digital Currency
eda.h
Go to the documentation of this file.
1 // Copyright (c) 2017-2020 The Bitcoin developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4 
5 #ifndef BITCOIN_POW_EDA_H
6 #define BITCOIN_POW_EDA_H
7 
8 #include <cstdint>
9 
10 class CBlockHeader;
11 class CBlockIndex;
12 
13 namespace Consensus {
14 struct Params;
15 }
16 
17 uint32_t CalculateNextWorkRequired(const CBlockIndex *pindexPrev,
18  int64_t nFirstBlockTime,
19  const Consensus::Params &params);
20 
21 uint32_t GetNextEDAWorkRequired(const CBlockIndex *pindexPrev,
22  const CBlockHeader *pblock,
23  const Consensus::Params &params);
24 
25 #endif // BITCOIN_POW_EDA_H
Parameters that influence chain consensus.
Definition: params.h:59
uint32_t GetNextEDAWorkRequired(const CBlockIndex *pindexPrev, const CBlockHeader *pblock, const Consensus::Params &params)
Compute the next required proof of work using the legacy Bitcoin difficulty adjustment + Emergency Di...
Definition: eda.cpp:45
The block chain is a tree shaped structure starting with the genesis block at the root...
Definition: blockindex.h:23
const CChainParams & Params()
Return the currently selected parameters.
uint32_t CalculateNextWorkRequired(const CBlockIndex *pindexPrev, int64_t nFirstBlockTime, const Consensus::Params &params)
Do difficulty adjustement Satoshi&#39;s way.
Definition: eda.cpp:14
Nodes collect new transactions into a block, hash them into a hash tree, and scan through nonce value...
Definition: block.h:22