Documentation
¶
Index ¶
- Constants
- Variables
- type CustomAllocation
- type Genesis
- type Rules
- func (*Rules) FetchCustom(string) (any, bool)
- func (r *Rules) GetBaseUnits() uint64
- func (r *Rules) GetBlockCostChangeDenominator() uint64
- func (r *Rules) GetMaxBlockTxs() int
- func (r *Rules) GetMaxBlockUnits() uint64
- func (r *Rules) GetMinBlockCost() uint64
- func (r *Rules) GetMinUnitPrice() uint64
- func (r *Rules) GetUnitPriceChangeDenominator() uint64
- func (r *Rules) GetValidityWindow() int64
- func (r *Rules) GetWarpBaseFee() uint64
- func (*Rules) GetWarpConfig(ids.ID) (bool, uint64, uint64)
- func (r *Rules) GetWarpFeePerSigner() uint64
- func (r *Rules) GetWindowTargetBlocks() uint64
- func (r *Rules) GetWindowTargetUnits() uint64
Constants ¶
View Source
const (
StateLockupField = "state_lockup"
)
Variables ¶
View Source
var ( ErrInvalidTarget = errors.New("invalid target") ErrStateLockupMissing = errors.New("state lockup parameter missing") )
Functions ¶
This section is empty.
Types ¶
type CustomAllocation ¶
type Genesis ¶
type Genesis struct {
// Address prefix
HRP string `json:"hrp"`
// Block params
MaxBlockTxs int `json:"maxBlockTxs"`
MaxBlockUnits uint64 `json:"maxBlockUnits"` // must be possible to reach before block too large
// Tx params
BaseUnits uint64 `json:"baseUnits"`
ValidityWindow int64 `json:"validityWindow"` // seconds
// Unit pricing
MinUnitPrice uint64 `json:"minUnitPrice"`
UnitPriceChangeDenominator uint64 `json:"unitPriceChangeDenominator"`
WindowTargetUnits uint64 `json:"windowTargetUnits"` // 10s
// Block pricing
MinBlockCost uint64 `json:"minBlockCost"`
BlockCostChangeDenominator uint64 `json:"blockCostChangeDenominator"`
WindowTargetBlocks uint64 `json:"windowTargetBlocks"` // 10s
// Warp pricing
WarpBaseFee uint64 `json:"warpBaseFee"`
WarpFeePerSigner uint64 `json:"warpFeePerSigner"`
// Allocations
CustomAllocation []*CustomAllocation `json:"customAllocation"`
}
type Rules ¶
type Rules struct {
// contains filtered or unexported fields
}
func (*Rules) GetBaseUnits ¶
func (*Rules) GetBlockCostChangeDenominator ¶
func (*Rules) GetMaxBlockTxs ¶
func (*Rules) GetMaxBlockUnits ¶
func (*Rules) GetMinBlockCost ¶
func (*Rules) GetMinUnitPrice ¶
func (*Rules) GetUnitPriceChangeDenominator ¶
func (*Rules) GetValidityWindow ¶
func (*Rules) GetWarpBaseFee ¶
func (*Rules) GetWarpFeePerSigner ¶
func (*Rules) GetWindowTargetBlocks ¶
func (*Rules) GetWindowTargetUnits ¶
Click to show internal directories.
Click to hide internal directories.