Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Adjuster ¶
type Adjuster struct {
// contains filtered or unexported fields
}
func NewAdjuster ¶
func (*Adjuster) GetNextDifficulty ¶
type Calculator ¶
type Calculator struct {
// contains filtered or unexported fields
}
func NewCalculator ¶
func NewCalculator(targetBlockTime, windowSize int64) *Calculator
type TargetCalculator ¶
type TargetCalculator struct {
// contains filtered or unexported fields
}
TargetCalculator calculates mining targets based on difficulty
func NewTargetCalculator ¶
func NewTargetCalculator(maxTargetHex string) *TargetCalculator
func (*TargetCalculator) DifficultyToTarget ¶
func (tc *TargetCalculator) DifficultyToTarget(difficulty uint32) *big.Int
func (*TargetCalculator) TargetToDifficulty ¶
func (tc *TargetCalculator) TargetToDifficulty(target *big.Int) uint32
Click to show internal directories.
Click to hide internal directories.