aboutsummaryrefslogtreecommitdiff
path: root/src/chainparams.h
diff options
context:
space:
mode:
authorCory Fields <cory-nospam-@coryfields.com>2015-06-05 15:36:34 -0400
committerCory Fields <cory-nospam-@coryfields.com>2015-07-28 15:26:50 -0400
commitf0deec572b304663f5f8e93a573f414e563b353f (patch)
tree87d5d6076ecac2cfbac1412fec36ab600eaeb966 /src/chainparams.h
parenteddaba7b5692288087a926da5733e86b47274e4e (diff)
chainparams: move CCheckpointData into chainparams.h
This unties CChainParams from its dependency on checkpoints. Instead, now it only depends on the raw checkpoint data.
Diffstat (limited to 'src/chainparams.h')
-rw-r--r--src/chainparams.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/chainparams.h b/src/chainparams.h
index 66d865b620..5db39aa09c 100644
--- a/src/chainparams.h
+++ b/src/chainparams.h
@@ -7,7 +7,6 @@
#define BITCOIN_CHAINPARAMS_H
#include "chainparamsbase.h"
-#include "checkpoints.h"
#include "consensus/params.h"
#include "primitives/block.h"
#include "protocol.h"
@@ -24,6 +23,14 @@ struct SeedSpec6 {
uint16_t port;
};
+typedef std::map<int, uint256> MapCheckpoints;
+
+struct CCheckpointData {
+ MapCheckpoints mapCheckpoints;
+ int64_t nTimeLastCheckpoint;
+ int64_t nTransactionsLastCheckpoint;
+ double fTransactionsPerDay;
+};
/**
* CChainParams defines various tweakable parameters of a given instance of the
@@ -67,7 +74,7 @@ public:
const std::vector<CDNSSeedData>& DNSSeeds() const { return vSeeds; }
const std::vector<unsigned char>& Base58Prefix(Base58Type type) const { return base58Prefixes[type]; }
const std::vector<SeedSpec6>& FixedSeeds() const { return vFixedSeeds; }
- const Checkpoints::CCheckpointData& Checkpoints() const { return checkpointData; }
+ const CCheckpointData& Checkpoints() const { return checkpointData; }
protected:
CChainParams() {}
@@ -87,7 +94,7 @@ protected:
bool fRequireStandard;
bool fMineBlocksOnDemand;
bool fTestnetToBeDeprecatedFieldRPC;
- Checkpoints::CCheckpointData checkpointData;
+ CCheckpointData checkpointData;
};
/**