app

package
v0.0.0-...-7040973 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2020 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// DefaultCLIHome default home directories for mchancli
	DefaultCLIHome = os.ExpandEnv("$HOME/.mchancli")

	// DefaultNodeHome default home directories for mchand
	DefaultNodeHome = os.ExpandEnv("$HOME/.mchand")

	// ModuleBasics ModuleManager is in charge of setting up basic module elements
	// e.g.: codec registration, genesis verification
	ModuleBasics = module.NewBasicManager(
		genaccounts.AppModuleBasic{},
		genutil.AppModuleBasic{},
		auth.AppModuleBasic{},
		bank.AppModuleBasic{},
		staking.AppModuleBasic{},
		mint.AppModuleBasic{},
		distr.AppModuleBasic{},
		gov.NewAppModuleBasic(paramsclient.ProposalHandler, distr.ProposalHandler),
		params.AppModuleBasic{},
		crisis.AppModuleBasic{},
		slashing.AppModuleBasic{},
		supply.AppModuleBasic{},
	)
)

Functions

func MakeCodec

func MakeCodec() *codec.Codec

MakeCodec generates the necessary codecs for Amino

Types

type GenesisState

type GenesisState map[string]json.RawMessage

GenesisState The genesis state of the blockchain is represented here as a map of raw json messages key'd by a identifier string. The identifier is used to determine which module genesis information belongs to so it may be appropriately routed during init chain. Within this application default genesis information is retrieved from the ModuleBasicManager which populates json from each BasicModule object provided to it during init.

func NewDefaultGenesisState

func NewDefaultGenesisState() GenesisState

NewDefaultGenesisState generates the default state for the application.

type MchanApp

type MchanApp struct {
	*bam.BaseApp
	// contains filtered or unexported fields
}

MChanApp extended ABCI application

func NewMchanApp

func NewMchanApp(logger log.Logger, db dbm.DB, traceStore io.Writer, loadLatest bool, invCheckPeriod uint,
	baseAppOptions ...func(*bam.BaseApp)) *MchanApp

MchanApp returns a reference to an initialized MchanApp.

func (*MchanApp) BeginBlocker

func (app *MchanApp) BeginBlocker(ctx sdk.Context, req abci.RequestBeginBlock) abci.ResponseBeginBlock

BeginBlocker application updates every begin block

func (*MchanApp) EndBlocker

func (app *MchanApp) EndBlocker(ctx sdk.Context, req abci.RequestEndBlock) abci.ResponseEndBlock

EndBlocker application updates every end block

func (*MchanApp) ExportAppStateAndValidators

func (app *MchanApp) ExportAppStateAndValidators(forZeroHeight bool, jailWhiteList []string,
) (appState json.RawMessage, validators []tmtypes.GenesisValidator, err error)

ExportAppStateAndValidators export the state of vspk for a genesis file

func (*MchanApp) InitChainer

func (app *MchanApp) InitChainer(ctx sdk.Context, req abci.RequestInitChain) abci.ResponseInitChain

InitChainer handles translating the genesis.json file into initial state for the network.

func (*MchanApp) LoadHeight

func (app *MchanApp) LoadHeight(height int64) error

LoadHeight load a particular height

func (*MchanApp) ModuleAccountAddrs

func (app *MchanApp) ModuleAccountAddrs() map[string]bool

ModuleAccountAddrs returns all the app's module account addresses.

Jump to

Keyboard shortcuts

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