staking

package
v0.0.0-...-1ac23cf Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Commission

type Commission struct {
	Rate          string    `json:"rate"`
	MaxRate       string    `json:"max_rate"`
	MaxChangeRate string    `json:"max_change_rate"`
	UpdatedAt     time.Time `json:"updated_at"`
}

type Delegation

type Delegation struct {
	DelegatorAddress string      `json:"delegator_address"`
	ValidatorAddress string      `json:"validator_address"`
	Shares           string      `json:"shares"`
	Balance          common.Coin `json:"balance"`
}

func NewDelegationFromRaw

func NewDelegationFromRaw(item stakingtypes.DelegationResponse) Delegation

type Delegations

type Delegations []Delegation

func NewDelegationsFromRaw

func NewDelegationsFromRaw(items stakingtypes.DelegationResponses) Delegations

type Description

type Description struct {
	Moniker         string `json:"moniker"`
	Identity        string `json:"identity"`
	Website         string `json:"website"`
	SecurityContact string `json:"security_contact"`
	Details         string `json:"details"`
}

type Validator

type Validator struct {
	OperatorAddress   string      `json:"operator_address"`
	ConsensusPubKey   string      `json:"consensus_pub_key"`
	Jailed            bool        `json:"jailed"`
	Status            string      `json:"status"`
	Tokens            int64       `json:"tokens"`
	DelegatorShares   string      `json:"delegator_shares"`
	Description       Description `json:"description"`
	UnbondingHeight   int64       `json:"unbonding_height"`
	UnbondingTime     time.Time   `json:"unbonding_time"`
	Commission        Commission  `json:"commission"`
	MinSelfDelegation int64       `json:"min_self_delegation"`
	ConsensusPower    int64       `json:"consensus_power"`
}

func NewValidatorFromRaw

func NewValidatorFromRaw(item *stakingtypes.Validator) Validator

type Validators

type Validators []Validator

func NewValidatorsFromRaw

func NewValidatorsFromRaw(items stakingtypes.Validators) Validators

Jump to

Keyboard shortcuts

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