|
|
|
@ -12,13 +12,11 @@
@@ -12,13 +12,11 @@
|
|
|
|
|
|
|
|
|
|
#include <vector> |
|
|
|
|
|
|
|
|
|
using namespace std; |
|
|
|
|
|
|
|
|
|
typedef unsigned char MessageStartChars[MESSAGE_START_SIZE]; |
|
|
|
|
|
|
|
|
|
struct CDNSSeedData { |
|
|
|
|
string name, host; |
|
|
|
|
CDNSSeedData(const string &strName, const string &strHost) : name(strName), host(strHost) {} |
|
|
|
|
std::string name, host; |
|
|
|
|
CDNSSeedData(const std::string &strName, const std::string &strHost) : name(strName), host(strHost) {} |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -51,7 +49,7 @@ public:
@@ -51,7 +49,7 @@ public:
|
|
|
|
|
|
|
|
|
|
const uint256& HashGenesisBlock() const { return hashGenesisBlock; } |
|
|
|
|
const MessageStartChars& MessageStart() const { return pchMessageStart; } |
|
|
|
|
const vector<unsigned char>& AlertKey() const { return vAlertPubKey; } |
|
|
|
|
const std::vector<unsigned char>& AlertKey() const { return vAlertPubKey; } |
|
|
|
|
int GetDefaultPort() const { return nDefaultPort; } |
|
|
|
|
const uint256& ProofOfWorkLimit() const { return bnProofOfWorkLimit; } |
|
|
|
|
int SubsidyHalvingInterval() const { return nSubsidyHalvingInterval; } |
|
|
|
@ -74,16 +72,16 @@ public:
@@ -74,16 +72,16 @@ public:
|
|
|
|
|
bool RequireStandard() const { return fRequireStandard; } |
|
|
|
|
/* Make standard checks */ |
|
|
|
|
bool RPCisTestNet() const { return fRPCisTestNet; } |
|
|
|
|
const string& DataDir() const { return strDataDir; } |
|
|
|
|
const std::string& DataDir() const { return strDataDir; } |
|
|
|
|
/* Make miner stop after a block is found. In RPC, don't return
|
|
|
|
|
* until nGenProcLimit blocks are generated */ |
|
|
|
|
bool MineBlocksOnDemand() const { return fMineBlocksOnDemand; } |
|
|
|
|
Network NetworkID() const { return networkID; } |
|
|
|
|
/* Return the BIP70 network string (main, test or regtest) */ |
|
|
|
|
std::string NetworkIDString() const { return strNetworkID; } |
|
|
|
|
const vector<CDNSSeedData>& DNSSeeds() const { return vSeeds; } |
|
|
|
|
const std::vector<CDNSSeedData>& DNSSeeds() const { return vSeeds; } |
|
|
|
|
const std::vector<unsigned char>& Base58Prefix(Base58Type type) const { return base58Prefixes[type]; } |
|
|
|
|
const vector<CAddress>& FixedSeeds() const { return vFixedSeeds; } |
|
|
|
|
const std::vector<CAddress>& FixedSeeds() const { return vFixedSeeds; } |
|
|
|
|
int RPCPort() const { return nRPCPort; } |
|
|
|
|
protected: |
|
|
|
|
CChainParams() {} |
|
|
|
@ -91,7 +89,7 @@ protected:
@@ -91,7 +89,7 @@ protected:
|
|
|
|
|
uint256 hashGenesisBlock; |
|
|
|
|
MessageStartChars pchMessageStart; |
|
|
|
|
// Raw pub key bytes for the broadcast alert signing key.
|
|
|
|
|
vector<unsigned char> vAlertPubKey; |
|
|
|
|
std::vector<unsigned char> vAlertPubKey; |
|
|
|
|
int nDefaultPort; |
|
|
|
|
int nRPCPort; |
|
|
|
|
uint256 bnProofOfWorkLimit; |
|
|
|
@ -99,14 +97,14 @@ protected:
@@ -99,14 +97,14 @@ protected:
|
|
|
|
|
int nEnforceBlockUpgradeMajority; |
|
|
|
|
int nRejectBlockOutdatedMajority; |
|
|
|
|
int nToCheckBlockUpgradeMajority; |
|
|
|
|
string strDataDir; |
|
|
|
|
std::string strDataDir; |
|
|
|
|
int nMinerThreads; |
|
|
|
|
vector<CDNSSeedData> vSeeds; |
|
|
|
|
std::vector<CDNSSeedData> vSeeds; |
|
|
|
|
std::vector<unsigned char> base58Prefixes[MAX_BASE58_TYPES]; |
|
|
|
|
Network networkID; |
|
|
|
|
std::string strNetworkID; |
|
|
|
|
CBlock genesis; |
|
|
|
|
vector<CAddress> vFixedSeeds; |
|
|
|
|
std::vector<CAddress> vFixedSeeds; |
|
|
|
|
bool fRequireRPCPassword; |
|
|
|
|
bool fMiningRequiresPeers; |
|
|
|
|
bool fDefaultCheckMemPool; |
|
|
|
|