Documentation ¶
Index ¶
- Constants
- Variables
- func EstimateDecredSupply(params *DecredSubsidyParams, height int64, BlockOneSubsidy int64) int64
- func EstimateSupplyWithCache(cache map[int64]*int64, height int64, ...) int64
- func GenesisBlockPowBits() uint32
- func GenesisBlockTimestamp() time.Time
- func MinStakeDifficulty() int64
- func NetworkPoWLimit() *difficulty.Difficulty
- func OrganizationPkScript() []byte
- func Premine() map[string]coin.Amount
- type BlockByBlockSupplyEstimator
- type DecredSubsidyParams
- type PicfightCoinSubsidyCalculator
- func (c *PicfightCoinSubsidyCalculator) BlockTaxProportion() uint16
- func (c *PicfightCoinSubsidyCalculator) CalcBlockSubsidy(height int64) int64
- func (c *PicfightCoinSubsidyCalculator) CalcBlockTaxSubsidy(height int64, voters uint16) int64
- func (c *PicfightCoinSubsidyCalculator) CalcBlockWorkSubsidy(height int64, voters uint16) int64
- func (c *PicfightCoinSubsidyCalculator) CalcStakeVoteSubsidy(height int64) int64
- func (c *PicfightCoinSubsidyCalculator) EstimateSupply(height int64) int64
- func (c *PicfightCoinSubsidyCalculator) ExpectedTotalNetworkSubsidy() coin.Amount
- func (c *PicfightCoinSubsidyCalculator) FirstGeneratingBlockIndex() int64
- func (c *PicfightCoinSubsidyCalculator) NumberOfGeneratingBlocks() int64
- func (c *PicfightCoinSubsidyCalculator) PreminedCoins() coin.Amount
- func (c *PicfightCoinSubsidyCalculator) SetEngine(engine bignum.BigNumEngine)
- func (c *PicfightCoinSubsidyCalculator) StakeRewardProportion() uint16
- func (c *PicfightCoinSubsidyCalculator) StakeValidationHeight() int64
- func (c *PicfightCoinSubsidyCalculator) SubsidyReductionInterval() int64
- func (c *PicfightCoinSubsidyCalculator) TicketsPerBlock() uint16
- func (c *PicfightCoinSubsidyCalculator) WorkRewardProportion() uint16
- type SubsidyCalculator
Constants ¶
View Source
const NetworkAddressPrefix = "J"
View Source
const PROJECT_PREMINE_ADDRESS_STRING = "JsKFRL5ivSH7CnYaTtaBT4M9fZG878g49Fg"
View Source
const PROJECT_PREMINE_POS_ADDRESS_STRING = "JsRjbYZ448FxZQ5kQAc15NcwUQ1oqYydVEG"
View Source
const PicfightCoinWire uint32 = 0xd9b488ff
PicfightCoinWire represents the picfight coin network.
Variables ¶
View Source
var ( // Address encoding magics PubKeyAddrID = [2]byte{0x1b, 0x2d} // starts with Jk PubKeyHashAddrID = [2]byte{0x0a, 0x0f} // starts with Js PKHEdwardsAddrID = [2]byte{0x09, 0xef} // starts with Je PKHSchnorrAddrID = [2]byte{0x09, 0xd1} // starts with JS ScriptHashAddrID = [2]byte{0x09, 0xea} // starts with Jc PrivateKeyID = [2]byte{0x22, 0xce} // starts with Pj )
View Source
var PremineTotal = calcPremineTotal()
Functions ¶
func EstimateDecredSupply ¶
func EstimateDecredSupply(params *DecredSubsidyParams, height int64, BlockOneSubsidy int64) int64
func EstimateSupplyWithCache ¶
func GenesisBlockPowBits ¶
func GenesisBlockPowBits() uint32
func GenesisBlockTimestamp ¶
func MinStakeDifficulty ¶
func MinStakeDifficulty() int64
func NetworkPoWLimit ¶
func NetworkPoWLimit() *difficulty.Difficulty
NetworkPoWLimit is proof-of-work limit parameter.
func OrganizationPkScript ¶
func OrganizationPkScript() []byte
Organization related parameters Organization address is ?
Types ¶
type BlockByBlockSupplyEstimator ¶
type BlockByBlockSupplyEstimator struct { SubsidyCalculator SubsidyCalculator // contains filtered or unexported fields }
func (*BlockByBlockSupplyEstimator) Estimate ¶
func (c *BlockByBlockSupplyEstimator) Estimate(height int64) int64
type DecredSubsidyParams ¶
type DecredSubsidyParams struct { // BaseSubsidy is the starting subsidy amount for mined blocks. BaseSubsidy int64 // Subsidy reduction multiplier. MulSubsidy int64 // Subsidy reduction divisor. DivSubsidy int64 // SubsidyReductionInterval is the reduction interval in blocks. SubsidyReductionInterval int64 }
type PicfightCoinSubsidyCalculator ¶
type PicfightCoinSubsidyCalculator struct {
// contains filtered or unexported fields
}
func (*PicfightCoinSubsidyCalculator) BlockTaxProportion ¶
func (c *PicfightCoinSubsidyCalculator) BlockTaxProportion() uint16
func (*PicfightCoinSubsidyCalculator) CalcBlockSubsidy ¶
func (c *PicfightCoinSubsidyCalculator) CalcBlockSubsidy(height int64) int64
func (*PicfightCoinSubsidyCalculator) CalcBlockTaxSubsidy ¶
func (c *PicfightCoinSubsidyCalculator) CalcBlockTaxSubsidy(height int64, voters uint16) int64
func (*PicfightCoinSubsidyCalculator) CalcBlockWorkSubsidy ¶
func (c *PicfightCoinSubsidyCalculator) CalcBlockWorkSubsidy(height int64, voters uint16) int64
func (*PicfightCoinSubsidyCalculator) CalcStakeVoteSubsidy ¶
func (c *PicfightCoinSubsidyCalculator) CalcStakeVoteSubsidy(height int64) int64
func (*PicfightCoinSubsidyCalculator) EstimateSupply ¶
func (c *PicfightCoinSubsidyCalculator) EstimateSupply(height int64) int64
func (*PicfightCoinSubsidyCalculator) ExpectedTotalNetworkSubsidy ¶
func (c *PicfightCoinSubsidyCalculator) ExpectedTotalNetworkSubsidy() coin.Amount
func (*PicfightCoinSubsidyCalculator) FirstGeneratingBlockIndex ¶
func (c *PicfightCoinSubsidyCalculator) FirstGeneratingBlockIndex() int64
func (*PicfightCoinSubsidyCalculator) NumberOfGeneratingBlocks ¶
func (c *PicfightCoinSubsidyCalculator) NumberOfGeneratingBlocks() int64
func (*PicfightCoinSubsidyCalculator) PreminedCoins ¶
func (c *PicfightCoinSubsidyCalculator) PreminedCoins() coin.Amount
func (*PicfightCoinSubsidyCalculator) SetEngine ¶
func (c *PicfightCoinSubsidyCalculator) SetEngine(engine bignum.BigNumEngine)
func (*PicfightCoinSubsidyCalculator) StakeRewardProportion ¶
func (c *PicfightCoinSubsidyCalculator) StakeRewardProportion() uint16
func (*PicfightCoinSubsidyCalculator) StakeValidationHeight ¶
func (c *PicfightCoinSubsidyCalculator) StakeValidationHeight() int64
func (*PicfightCoinSubsidyCalculator) SubsidyReductionInterval ¶
func (c *PicfightCoinSubsidyCalculator) SubsidyReductionInterval() int64
func (*PicfightCoinSubsidyCalculator) TicketsPerBlock ¶
func (c *PicfightCoinSubsidyCalculator) TicketsPerBlock() uint16
func (*PicfightCoinSubsidyCalculator) WorkRewardProportion ¶
func (c *PicfightCoinSubsidyCalculator) WorkRewardProportion() uint16
type SubsidyCalculator ¶
type SubsidyCalculator interface { ExpectedTotalNetworkSubsidy() coin.Amount NumberOfGeneratingBlocks() int64 PreminedCoins() coin.Amount FirstGeneratingBlockIndex() int64 CalcBlockWorkSubsidy(height int64, voters uint16) int64 CalcStakeVoteSubsidy(height int64) int64 CalcBlockTaxSubsidy(height int64, voters uint16) int64 CalcBlockSubsidy(height int64) int64 TicketsPerBlock() uint16 SetEngine(engine bignum.BigNumEngine) EstimateSupply(height int64) int64 WorkRewardProportion() uint16 StakeRewardProportion() uint16 BlockTaxProportion() uint16 StakeValidationHeight() int64 }
func DecredMainNetSubsidy ¶
func DecredMainNetSubsidy() SubsidyCalculator
func PicFightCoinSubsidy ¶
func PicFightCoinSubsidy() SubsidyCalculator
Click to show internal directories.
Click to hide internal directories.