veriblock-pop-cpp
C++11 Libraries for leveraging VeriBlock Proof-Of-Proof blockchain technology.
altintegration::VbkChainParamsTest Struct Reference

TestNet VBK config. More...

Detailed Description

Definition at line 123 of file vbk_chain_params.hpp.

#include <vbk_chain_params.hpp>

+ Inheritance diagram for altintegration::VbkChainParamsTest:
+ Collaboration diagram for altintegration::VbkChainParamsTest:

Public Member Functions

int getProgPowForkHeight () const override
 
uint32_t getProgPowStartTimeEpoch () const noexcept override
 
const char * networkName () const override
 
uint32_t numBlocksForBootstrap () const noexcept override
 
uint256 getMinimumDifficulty () const override
 
VbkNetworkType getTransactionMagicByte () const noexcept override
 
bool getPowNoRetargeting () const noexcept override
 
bool EnableTimeAdjustment () const noexcept override
 In miner it is hard to simulate correct timestamps, so this flag disables Time Adjustment Algorithm in POP Fork Resolution. More...
 
uint32_t getRetargetPeriod () const noexcept override
 
uint32_t getTargetBlockTime () const noexcept override
 
- Public Member Functions inherited from altintegration::VbkChainParams
virtual int getProgPowForkHeight () const =0
 
virtual uint32_t getProgPowStartTimeEpoch () const noexcept=0
 
virtual bool isProgPowStartTimeEpochEnabled () const noexcept
 
virtual const char * networkName () const =0
 
virtual uint256 getMinimumDifficulty () const =0
 
virtual VbkNetworkType getTransactionMagicByte () const noexcept=0
 
virtual bool getPowNoRetargeting () const noexcept=0
 
virtual uint32_t getRetargetPeriod () const noexcept=0
 
virtual uint32_t getTargetBlockTime () const noexcept=0
 
virtual uint32_t numBlocksForBootstrap () const noexcept=0
 
virtual uint32_t maxFutureBlockTime () const noexcept
 
virtual bool EnableTimeAdjustment () const noexcept=0
 In miner it is hard to simulate correct timestamps, so this flag disables Time Adjustment Algorithm in POP Fork Resolution. More...
 
virtual int32_t getMaxReorgBlocks () const noexcept
 
virtual uint32_t getKeystoneInterval () const noexcept
 
virtual uint32_t getFinalityDelay () const noexcept
 
virtual int32_t getOldBlocksWindow () const noexcept
 all blocks further than this number of blocks are considered "old" More...
 
virtual const std::vector< uint32_t > & getForkResolutionLookUpTable () const noexcept
 
virtual int32_t getEndorsementSettlementInterval () const noexcept
 
uint32_t preserveBlocksBehindFinal () const noexcept
 when finalizeBlockImpl is called, this many blocks behind final block will be preserved in RAM. More...
 

Additional Inherited Members

- Public Attributes inherited from altintegration::VbkChainParams
uint32_t mOldBlocksWindow = 12000
 
uint32_t mEndorsementSettlementInterval = 400
 
uint32_t mPreserveBlocksBehindFinal = mEndorsementSettlementInterval
 
int32_t mMaxReorgBlocks = VBK_MAX_REORG_BLOCKS_MIN_VALUE
 
- Protected Attributes inherited from altintegration::VbkChainParams
uint32_t mMaxFutureBlockTime = 5 * 60
 
std::vector< uint32_t > forkResolutionLookUpTable_
 

Member Function Documentation

◆ EnableTimeAdjustment()

bool altintegration::VbkChainParamsTest::EnableTimeAdjustment ( ) const
inlineoverridevirtualnoexcept

Set it to TRUE in production, and to FALSE in tests.

Implements altintegration::VbkChainParams.

Definition at line 150 of file vbk_chain_params.hpp.

150{ return true; }

◆ getMinimumDifficulty()

uint256 altintegration::VbkChainParamsTest::getMinimumDifficulty ( ) const
inlineoverridevirtual

Implements altintegration::VbkChainParams.

Definition at line 138 of file vbk_chain_params.hpp.

138 {
139 return ArithUint256::fromHex("05F5E100");
140 }
static ArithUint256 fromHex(const std::string &hex)

◆ getPowNoRetargeting()

bool altintegration::VbkChainParamsTest::getPowNoRetargeting ( ) const
inlineoverridevirtualnoexcept

Implements altintegration::VbkChainParams.

Definition at line 148 of file vbk_chain_params.hpp.

148{ return false; }

◆ getProgPowForkHeight()

int altintegration::VbkChainParamsTest::getProgPowForkHeight ( ) const
inlineoverridevirtual

Implements altintegration::VbkChainParams.

Definition at line 126 of file vbk_chain_params.hpp.

126{ return 872000; }

◆ getProgPowStartTimeEpoch()

uint32_t altintegration::VbkChainParamsTest::getProgPowStartTimeEpoch ( ) const
inlineoverridevirtualnoexcept

Implements altintegration::VbkChainParams.

Definition at line 127 of file vbk_chain_params.hpp.

127 {
128 return 1600444017U;
129 }

◆ getRetargetPeriod()

uint32_t altintegration::VbkChainParamsTest::getRetargetPeriod ( ) const
inlineoverridevirtualnoexcept

Implements altintegration::VbkChainParams.

Definition at line 152 of file vbk_chain_params.hpp.

152{ return 100; }

◆ getTargetBlockTime()

uint32_t altintegration::VbkChainParamsTest::getTargetBlockTime ( ) const
inlineoverridevirtualnoexcept

Implements altintegration::VbkChainParams.

Definition at line 154 of file vbk_chain_params.hpp.

154{ return 30; }

◆ getTransactionMagicByte()

VbkNetworkType altintegration::VbkChainParamsTest::getTransactionMagicByte ( ) const
inlineoverridevirtualnoexcept

Implements altintegration::VbkChainParams.

Definition at line 142 of file vbk_chain_params.hpp.

142 {
143 VbkNetworkType r;
144 r.hasValue = true;
145 r.value = 0xAA;
146 return r;
147 }

◆ networkName()

const char * altintegration::VbkChainParamsTest::networkName ( ) const
inlineoverridevirtual

Implements altintegration::VbkChainParams.

Definition at line 131 of file vbk_chain_params.hpp.

131{ return "test"; }

◆ numBlocksForBootstrap()

uint32_t altintegration::VbkChainParamsTest::numBlocksForBootstrap ( ) const
inlineoverridevirtualnoexcept

Implements altintegration::VbkChainParams.

Definition at line 133 of file vbk_chain_params.hpp.

133 {
134 return getRetargetPeriod();
135 }

The documentation for this struct was generated from the following file: