types

package
v0.0.0-...-bd61a53 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// module name
	ModuleName = "mining"

	// StoreKey is the default store key for guardian
	StoreKey = ModuleName

	// RouterKey is the message route for guardian
	RouterKey = ModuleName

	// QuerierRoute is the querier route for the guardian store.
	QuerierRoute = StoreKey
)
View Source
const (
	DefaultParamspace = ModuleName
)

Default parameter namespace

View Source
const (
	QueryRewards = "queryRewards"
)
View Source
const (
	TypeMsgRegister = "withDraw"
)

Variables

View Source
var ModuleCdc = codec.New()

ModuleCdc defines the codec to be used by evm module

Functions

func RegisterCodec

func RegisterCodec(cdc *codec.Codec)

RegisterCodec registers concrete types and interfaces on the given codec.

Types

type CodeType

type CodeType = sdk.CodeType
const (
	DefaultCodespace sdk.CodespaceType = ModuleName

	CodeInvalidInput   CodeType = 101
	CodeInvalidAddress CodeType = sdk.CodeInvalidAddress
	CodeUnauthorized   CodeType = sdk.CodeUnauthorized
	CodeInternal       CodeType = sdk.CodeInternal
	CodeUnknownRequest CodeType = sdk.CodeUnknownRequest
)

type MsgWithDraw

type MsgWithDraw struct {
	RemoteAccount []byte `json:"account"`   // source chain account
	MyAddress     []byte `json:"myAddress"` // binding address with local address
	Amount        uint64 `json:"amount"`    // the number
}

func NewMsgWithDraw

func NewMsgWithDraw(sourceAccount []byte, myAddress []byte, amount uint64) *MsgWithDraw

func (MsgWithDraw) GetMsgs

func (msg MsgWithDraw) GetMsgs() []sdk.Msg

GetMsgs returns a single MsgSetAccName as an sdk.Msg.

func (MsgWithDraw) GetSignBytes

func (msg MsgWithDraw) GetSignBytes() []byte

GetSignBytes encodes the message for signing

func (MsgWithDraw) GetSigners

func (msg MsgWithDraw) GetSigners() []sdk.AccAddress

GetSigners defines whose signature is required

func (MsgWithDraw) Route

func (msg MsgWithDraw) Route() string

Route should return the name of the module

func (MsgWithDraw) Type

func (msg MsgWithDraw) Type() string

Type should return the action

func (MsgWithDraw) ValidateBasic

func (msg MsgWithDraw) ValidateBasic() sdk.Error

ValidateBasic runs stateless checks on the message

type QueryRewardsParams

type QueryRewardsParams struct {
	LocalAddr string
}

QueryInfoByOinParams defines the params to query map info by oin addr.

type QueryRewardsResponse

type QueryRewardsResponse struct {
	Rewards uint64 `json:"rewards"`
}

func (QueryRewardsResponse) String

func (q QueryRewardsResponse) String() string

type RewardsInfo

type RewardsInfo struct {
	Rewards big.Int // 未提现收益
}

Jump to

Keyboard shortcuts

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