6 #ifndef BITCOIN_CHAINPARAMS_H
7 #define BITCOIN_CHAINPARAMS_H
160 friend const std::vector<std::string>
172 int32_t nVersion,
const Amount genesisReward);
CBlock CreateGenesisBlock(uint32_t nTime, uint32_t nNonce, uint32_t nBits, int32_t nVersion, const Amount genesisReward)
Build the genesis block.
std::map< int, const AssumeutxoData > MapAssumeutxo
std::map< int, BlockHash > MapCheckpoints
const CCheckpointData & CheckpointData(const std::string &chain)
void SelectParams(const std::string &chain)
Sets the params returned by Params() to those for the given BIP70 chain name.
const CChainParams & Params()
Return the currently selected parameters.
std::unique_ptr< CChainParams > CreateChainParams(const std::string &chain)
Creates and returns a std::unique_ptr<CChainParams> of the chosen chain.
CChainParams defines various tweakable parameters of a given instance of the Bitcoin system.
uint64_t m_assumed_chain_state_size
const std::vector< uint8_t > & Base58Prefix(Base58Type type) const
Return the list of hostnames to look up for DNS seeds.
bool DefaultConsistencyChecks() const
Default value for -checkmempool and -checkblockindex argument.
std::string NetworkIDString() const
Return the BIP70 network string (main, test or regtest)
uint16_t GetDefaultPort(const std::string &addr) const
bool RequireStandard() const
Policy: Filter transactions that do not match well-defined patterns.
MapAssumeutxo m_assumeutxo_data
const ChainTxData & TxData() const
uint64_t m_assumed_blockchain_size
const CCheckpointData & Checkpoints() const
const CMessageHeader::MessageMagic & NetMagic() const
bool IsMockableChain() const
If this chain allows time to be mocked.
CMessageHeader::MessageMagic netMagic
std::vector< uint8_t > base58Prefixes[MAX_BASE58_TYPES]
bool fDefaultConsistencyChecks
std::vector< SeedSpec6 > vFixedSeeds
const MapAssumeutxo & Assumeutxo() const
Get allowed assumeutxo configuration.
bool IsTestChain() const
If this chain is exclusively used for testing.
bool MineBlocksOnDemand() const
Whether it is possible to mine blocks on demand (no retargeting)
const CMessageHeader::MessageMagic & DiskMagic() const
Consensus::Params consensus
const Consensus::Params & GetConsensus() const
const std::string & CashAddrPrefix() const
friend const std::vector< std::string > GetRandomizedDNSSeeds(const CChainParams ¶ms)
Return the list of hostnames to look up for DNS seeds.
uint16_t GetDefaultPort() const
uint64_t AssumedBlockchainSize() const
Minimum free space (in GB) needed for data directory.
std::string cashaddrPrefix
std::vector< std::string > vSeeds
CMessageHeader::MessageMagic diskMagic
uint64_t AssumedChainStateSize() const
Minimum free space (in GB) needed for data directory when pruned; Does not include prune target.
uint64_t PruneAfterHeight() const
CCheckpointData checkpointData
const std::vector< SeedSpec6 > & FixedSeeds() const
const CBlock & GenesisBlock() const
uint64_t nPruneAfterHeight
uint16_t GetDefaultPort(Network net) const
bool SetSpecial(const std::string &addr)
Parse a Tor or I2P address and set this object to it.
enum Network GetNetwork() const
static constexpr uint16_t I2P_SAM31_PORT
SAM 3.1 and earlier do not support specifying ports and force the port to 0.
Holds configuration for use during UTXO snapshot load and validation.
const AssumeutxoHash hash_serialized
The expected hash of the deserialized UTXO set.
const unsigned int nChainTx
Used to populate the nChainTx value, which is used during BlockManager::LoadBlockIndex().
AssumeutxoHash(const uint256 &hash)
MapCheckpoints mapCheckpoints
Holds various statistics on transactions within a chain.
Parameters that influence chain consensus.