exported

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2019 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DelegationI

type DelegationI interface {
	GetDelegatorAddr() sdk.AccAddress // delegator sdk.AccAddress for the bond
	GetValidatorAddr() sdk.ValAddress // validator operator address
	GetShares() sdk.Dec               // amount of validator's shares held in this delegation
}

DelegationI delegation bond for a delegated proof of stake system

type ValidatorI

type ValidatorI interface {
	IsJailed() bool                                             // whether the validator is jailed
	GetMoniker() string                                         // moniker of the validator
	GetStatus() sdk.BondStatus                                  // status of the validator
	IsBonded() bool                                             // check if has a bonded status
	IsUnbonded() bool                                           // check if has status unbonded
	IsUnbonding() bool                                          // check if has status unbonding
	GetOperator() sdk.ValAddress                                // operator address to receive/return validators tokens
	GetConsPubKey() crypto.PubKey                               // validation consensus pubkey
	GetConsAddr() sdk.ConsAddress                               // validation consensus address
	GetShares() sdk.Int                                         // validation shares
	GetBondedShares() sdk.Int                                   // validator bonded shares
	GetConsensusPower() int64                                   // validation power in tendermint
	GetCommission() sdk.Dec                                     // validator commission rate
	GetMinSelfDelegation() sdk.Int                              // validator minimum self delegation
	GetDelegatorShares() sdk.Dec                                // total outstanding delegator shares
	SharesFromPowers(sdk.Dec) sdk.Dec                           // share worth of provided delegator shares
	SharesFromPowersTruncated(sdk.Dec) sdk.Dec                  // share worth of provided delegator shares, truncated
	SharesFromPowersRoundUp(sdk.Dec) sdk.Dec                    // share worth of provided delegator shares, rounded up
	PowersFromShares(amt sdk.Int) (sdk.Dec, sdk.Error)          // shares worth of delegator's bond
	PowersFromSharesTruncated(amt sdk.Int) (sdk.Dec, sdk.Error) // truncated shares worth of delegator's bond
}

ValidatorI expected validator functions

Jump to

Keyboard shortcuts

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