app

package
v2.0.8 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	StakePerAccount                        = "stake_per_account"
	InitiallyBondedValidators              = "initially_bonded_validators"
	OpWeightDeductFee                      = "op_weight_deduct_fee"
	OpWeightMsgSend                        = "op_weight_msg_send"
	OpWeightMsgMultiSend                   = "op_weight_msg_multisend"
	OpWeightMsgSetWithdrawAddress          = "op_weight_msg_set_withdraw_address"
	OpWeightMsgWithdrawDelegationReward    = "op_weight_msg_withdraw_delegation_reward"
	OpWeightMsgWithdrawValidatorCommission = "op_weight_msg_withdraw_validator_commission"
	OpWeightSubmitTextProposal             = "op_weight_submit_text_proposal"
	OpWeightSubmitCommunitySpendProposal   = "op_weight_submit_community_spend_proposal"
	OpWeightSubmitParamChangeProposal      = "op_weight_submit_param_change_proposal"
	OpWeightMsgDeposit                     = "op_weight_msg_deposit"
	OpWeightMsgVote                        = "op_weight_msg_vote"
	OpWeightMsgCreateValidator             = "op_weight_msg_create_validator"
	OpWeightMsgEditValidator               = "op_weight_msg_edit_validator"
	OpWeightMsgDelegate                    = "op_weight_msg_delegate"
	OpWeightMsgUndelegate                  = "op_weight_msg_undelegate"
	OpWeightMsgBeginRedelegate             = "op_weight_msg_begin_redelegate"
	OpWeightMsgUnjail                      = "op_weight_msg_unjail"
)

Simulation parameter constants

Variables

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

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

	// ModuleBasics The module BasicManager is in charge of setting up basic,
	// non-dependant module elements, such as codec registration
	// and genesis verification.
	ModuleBasics = module.NewBasicManager(
		genutil.AppModuleBasic{},
		auth.AppModuleBasic{},
		bank.AppModuleBasic{},
		staking.AppModuleBasic{},
		mint.AppModuleBasic{},
		distr.AppModuleBasic{},
		gov.NewAppModuleBasic(paramsclient.ProposalHandler, distr.ProposalHandler, upgradeclient.ProposalHandler),
		params.AppModuleBasic{},
		crisis.AppModuleBasic{},
		slashing.AppModuleBasic{},
		supply.AppModuleBasic{},
		upgrade.AppModuleBasic{},
		evidence.AppModuleBasic{},
	)
)

Functions

func GetMaccPerms

func GetMaccPerms() map[string][]string

GetMaccPerms returns a mapping of the application's module account permissions.

func MakeCodec

func MakeCodec() *codec.Codec

MakeCodec creates and returns a reference to an Amino codec that has all the necessary types and interfaces registered. This codec is provided to all the modules the application depends on.

NOTE: This codec will be deprecated in favor of AppCodec once all modules are migrated.

Types

type Codec

type Codec struct {
	// contains filtered or unexported fields
}

Codec defines the application-level codec. This codec contains all the required module-specific codecs that are to be provided upon initialization.

func NewCodec

func NewCodec() *Codec

type GaiaApp

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

GaiaApp extended ABCI application

func NewGaiaApp

func NewGaiaApp(
	logger log.Logger, db dbm.DB, traceStore io.Writer, loadLatest bool,
	invCheckPeriod uint, skipUpgradeHeights map[int64]bool, baseAppOptions ...func(*bam.BaseApp),
) *GaiaApp

NewGaiaApp returns a reference to an initialized GaiaApp.

func (*GaiaApp) BeginBlocker

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

BeginBlocker application updates every begin block

func (*GaiaApp) Codec

func (app *GaiaApp) Codec() *codec.Codec

Codec returns the application's sealed codec.

func (*GaiaApp) EndBlocker

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

EndBlocker application updates every end block

func (*GaiaApp) ExportAppStateAndValidators

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

ExportAppStateAndValidators export the state of gaia for a genesis file

func (*GaiaApp) InitChainer

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

InitChainer application update at chain initialization

func (*GaiaApp) LoadHeight

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

LoadHeight loads a particular height

func (*GaiaApp) ModuleAccountAddrs

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

ModuleAccountAddrs returns all the app's module account addresses.

func (*GaiaApp) Name

func (app *GaiaApp) Name() string

Name returns the name of the App

func (*GaiaApp) SimulationManager

func (app *GaiaApp) SimulationManager() *module.SimulationManager

SimulationManager implements the SimulationApp interface

type GenesisState

type GenesisState map[string]json.RawMessage

GenesisState defines a type alias for the Gaia genesis application state.

func NewDefaultGenesisState

func NewDefaultGenesisState() GenesisState

NewDefaultGenesisState generates the default state for the application.

Jump to

Keyboard shortcuts

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