types

package
v0.15.0-rc0 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2018 License: Apache-2.0 Imports: 5 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAccountDecoder

func GetAccountDecoder(cdc *wire.Codec) sdk.AccountDecoder

Get the AccountDecoder function for the custom AppAccount

Types

type AppAccount

type AppAccount struct {
	auth.BaseAccount
	Name string `json:"name"`
}

Custom extensions for this application. This is just an example of extending auth.BaseAccount with custom fields.

This is compatible with the stock auth.AccountStore, since auth.AccountStore uses the flexible go-amino library.

func (AppAccount) GetName

func (acc AppAccount) GetName() string

nolint

func (*AppAccount) SetName

func (acc *AppAccount) SetName(name string)

type GenesisAccount

type GenesisAccount struct {
	Name    string      `json:"name"`
	Address sdk.Address `json:"address"`
	Coins   sdk.Coins   `json:"coins"`
}

GenesisAccount doesn't need pubkey or sequence

func NewGenesisAccount

func NewGenesisAccount(aa *AppAccount) *GenesisAccount

func (*GenesisAccount) ToAppAccount

func (ga *GenesisAccount) ToAppAccount() (acc *AppAccount, err error)

convert GenesisAccount to AppAccount

type GenesisState

type GenesisState struct {
	Accounts    []*GenesisAccount `json:"accounts"`
	PowGenesis  pow.PowGenesis    `json:"pow"`
	CoolGenesis cool.CoolGenesis  `json:"cool"`
}

State to Unmarshal

Jump to

Keyboard shortcuts

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