types

package
v0.0.0-...-4cb4d4a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 18, 2022 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	GenesisReword               = math.MustParseBig256("3000000000000000000") // 300DGC = 3ETH
	CarratReward                = math.MustParseBig256("3300000000000000000") // 330DGC = 3.3ETH
	DiffByShareValue            = int64(2000000000)
	CarrathardforkheightMainnet = int64(400000)
	CarrathardforkheightTestnet = int64(641800)
)

Functions

func GetConstReward

func GetConstReward(height int64, mainnet bool) *big.Int

func GetRewardForUncle

func GetRewardForUncle(height int64, mainnet bool) *big.Int

func GetUncleReward

func GetUncleReward(uHeight, height int64, mainnet bool) *big.Int

Types

type BlockData

type BlockData struct {
	Height         int64    `json:"height"`
	Timestamp      int64    `json:"timestamp"`
	Difficulty     int64    `json:"difficulty"`
	TotalShares    int64    `json:"shares"`
	Uncle          bool     `json:"uncle"`
	UncleHeight    int64    `json:"uncleHeight"`
	Orphan         bool     `json:"orphan"`
	Hash           string   `json:"hash"`
	Nonce          string   `json:"-"`
	PowHash        string   `json:"-"`
	MixDigest      string   `json:"-"`
	Reward         *big.Int `json:"-"`
	ExtraReward    *big.Int `json:"-"`
	ImmatureReward string   `json:"-"`
	RewardString   string   `json:"reward"`
	RoundHeight    int64    `json:"-"`
	CandidateKey   string
	ImmatureKey    string
	State          int
}

func (*BlockData) Key

func (b *BlockData) Key() string

func (*BlockData) RewardInShannon

func (b *BlockData) RewardInShannon() int64

func (*BlockData) RoundKey

func (b *BlockData) RoundKey() string

func (*BlockData) SerializeHash

func (b *BlockData) SerializeHash() string

type CreditsImmatrue

type CreditsImmatrue struct {
	Addr   string
	Amount int64
}

type DevSubList

type DevSubList struct {
	DevAddr string
	SubAddr string
	Amount  int64
}

type InboundIdList

type InboundIdList struct {
	Id      string
	Allowed bool   // true: allow false: deny
	Alarm   string // none, slack, mail
	Desc    string
}

type InboundIpList

type InboundIpList struct {
	Ip      string
	Allowed bool // true: allow false: deny
	Desc    string
}

type MinerCharts

type MinerCharts struct {
	Timestamp       int64  `json:"x"`
	TimeFormat      string `json:"timeFormat"`
	MinerHash       int64  `json:"minerHash"`
	MinerLargeHash  int64  `json:"minerLargeHash"`
	WorkerOnline    string `json:"workerOnline"`
	Share           int64  `json:"minerShare"`
	MinerReportHash int64  `json:"minerReportHash"`
}

type RewardData

type RewardData struct {
	Height    int64   `json:"blockheight"`
	Timestamp int64   `json:"timestamp"`
	BlockHash string  `json:"blockhash"`
	Reward    int64   `json:"reward"`
	Percent   float64 `json:"percent"`
	Immature  bool    `json:"immature"`
}

type UserInfo

type UserInfo struct {
	Username string `json:"username"`
	Access   string `json:"access"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL