Documentation
¶
Index ¶
- Variables
- func BeginBlockForks(ctx sdk.Context, app *DoApp)
- func GetMaccPerms() map[string][]string
- func HardenMainnetGenesisDefaults(genesis map[string]json.RawMessage)
- func MakeEncodingConfig() params.EncodingConfig
- func RegisterSwaggerAPI(rtr *mux.Router)
- type DoApp
- func (app *DoApp) AppCodec() codec.Codec
- func (app *DoApp) BasicModuleManager() module.BasicManager
- func (app *DoApp) BeginBlocker(ctx sdk.Context) (sdk.BeginBlock, error)
- func (app *DoApp) BlacklistedAccAddrs() map[string]bool
- func (app *DoApp) DefaultGenesis() map[string]json.RawMessage
- func (app *DoApp) EndBlocker(ctx sdk.Context) (sdk.EndBlock, error)
- func (app *DoApp) ExportAppStateAndValidators(forZeroHeight bool, jailAllowedAddrs, modulesToExport []string) (servertypes.ExportedApp, error)
- func (app *DoApp) GetSubspace(moduleName string) paramstypes.Subspace
- func (app *DoApp) GetTxConfig() client.TxConfig
- func (app *DoApp) InitChainer(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error)
- func (app *DoApp) InterfaceRegistry() codectypes.InterfaceRegistry
- func (app *DoApp) LegacyAmino() *codec.LegacyAmino
- func (app *DoApp) LoadHeight(height int64) error
- func (app *DoApp) ModuleAccountAddrs() map[string]bool
- func (app *DoApp) Modules() map[string]interface{}
- func (app *DoApp) Name() string
- func (app *DoApp) PreBlocker(ctx sdk.Context, _ *abci.RequestFinalizeBlock) (*sdk.ResponsePreBlock, error)
- func (app *DoApp) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig)
- func (app *DoApp) RegisterNodeService(clientCtx client.Context, config config.Config)
- func (app *DoApp) RegisterTendermintService(clientCtx client.Context)
- func (app *DoApp) RegisterTxService(clientCtx client.Context)
- func (app *DoApp) SimulationManager() *module.SimulationManager
- type GenesisState
Constants ¶
This section is empty.
Variables ¶
var ( // DefaultNodeHome defines default home directories for dochaind DefaultNodeHome string // Upgrades defines upgrades to be applied to the network Upgrades = []upgrades.Upgrade{ v2.Upgrade, v3.Upgrade, v4.Upgrade, v5.Upgrade, v6.Upgrade, v6_1.Upgrade, v7.Upgrade, v7_1.Upgrade, v8.Upgrade, v8_1.Upgrade, v8_2.Upgrade, v8_3.Upgrade, v10_1.Upgrade, v11.Upgrade, v11_1.Upgrade, v11_2.Upgrade, v12.Upgrade, v13.Upgrade, v13_1.Upgrade, v14_1.Upgrade, } // Forks defines forks to be applied to the network Forks = []upgrades.Fork{} )
var ( // ModuleBasics = The ModuleBasicManager is in charge of setting up basic, // non-dependant module elements, such as codec registration // and genesis verification. ModuleBasics = module.NewBasicManager( customauth.AppModuleBasic{}, customauthz.AppModuleBasic{}, genutil.NewAppModuleBasic(genutiltypes.DefaultMessageValidator), custombank.AppModuleBasic{}, customstaking.AppModuleBasic{}, custommint.AppModuleBasic{}, customdistr.AppModuleBasic{}, customgov.NewAppModuleBasic( []govclient.ProposalHandler{ paramsclient.ProposalHandler, }, ), customparams.AppModuleBasic{}, customslashing.AppModuleBasic{}, customfeegrant.AppModuleBasic{}, ibc.AppModuleBasic{}, ica.AppModuleBasic{}, ibctm.AppModuleBasic{}, customupgrade.AppModuleBasic{}, customevidence.AppModuleBasic{}, transfer.AppModuleBasic{}, vesting.AppModuleBasic{}, oracle.AppModuleBasic{}, market.AppModuleBasic{}, treasury.AppModuleBasic{}, customwasm.AppModuleBasic{}, dyncomm.AppModuleBasic{}, ibchooks.AppModuleBasic{}, consensus.AppModuleBasic{}, ) )
Functions ¶
func BeginBlockForks ¶
BeginBlockForks is intended to be ran in a chain upgrade.
func GetMaccPerms ¶
GetMaccPerms returns a copy of the module account permissions
func HardenMainnetGenesisDefaults ¶
func HardenMainnetGenesisDefaults(genesis map[string]json.RawMessage)
HardenMainnetGenesisDefaults applies conservative launch defaults to generated genesis state. It intentionally touches only genesis-facing params.
func MakeEncodingConfig ¶
func MakeEncodingConfig() params.EncodingConfig
MakeEncodingConfig creates an EncodingConfig for testing
func RegisterSwaggerAPI ¶
RegisterSwaggerAPI registers swagger route with API Server.
Types ¶
type DoApp ¶
type DoApp struct {
*baseapp.BaseApp
*keepers.AppKeepers
// contains filtered or unexported fields
}
DoApp extends an ABCI application, but with most of its parameters exported. They are exported for convenience in creating helper functions, as object capabilities aren't needed for testing.
func NewDoApp ¶
func NewDoApp( logger sdklog.Logger, db dbm.DB, traceStore io.Writer, loadLatest bool, skipUpgradeHeights map[int64]bool, homePath string, encodingConfig doappparams.EncodingConfig, appOpts servertypes.AppOptions, wasmOpts []wasmkeeper.Option, baseAppOptions ...func(*baseapp.BaseApp), ) *DoApp
NewDoApp returns a reference to an initialized DoApp.
func (*DoApp) AppCodec ¶
AppCodec returns Gaia's app codec.
NOTE: This is solely to be used for testing purposes as it may be desirable for modules to register their own custom testing types.
func (*DoApp) BasicModuleManager ¶
func (app *DoApp) BasicModuleManager() module.BasicManager
BasicModuleManager returns a BasicManager derived from the app's module manager. This is useful for CLI wiring where module Basic instances must be fully initialized (e.g., with codecs) to construct tx/query commands safely.
func (*DoApp) BeginBlocker ¶
BeginBlocker application updates every begin block
func (*DoApp) BlacklistedAccAddrs ¶
BlacklistedAccAddrs returns all the app's module account addresses black listed for receiving tokens.
func (*DoApp) DefaultGenesis ¶
func (app *DoApp) DefaultGenesis() map[string]json.RawMessage
DefaultGenesis returns a default genesis from the registered AppModuleBasic's.
func (*DoApp) EndBlocker ¶
EndBlocker application updates every end block
func (*DoApp) ExportAppStateAndValidators ¶
func (app *DoApp) ExportAppStateAndValidators( forZeroHeight bool, jailAllowedAddrs, modulesToExport []string, ) (servertypes.ExportedApp, error)
ExportAppStateAndValidators exports the state of the application for a genesis file.
func (*DoApp) GetSubspace ¶
func (app *DoApp) GetSubspace(moduleName string) paramstypes.Subspace
GetSubspace returns a param subspace for a given module name.
NOTE: This is solely to be used for testing purposes.
func (*DoApp) InitChainer ¶
func (app *DoApp) InitChainer(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error)
InitChainer application update at chain initialization
func (*DoApp) InterfaceRegistry ¶
func (app *DoApp) InterfaceRegistry() codectypes.InterfaceRegistry
InterfaceRegistry returns Gaia's InterfaceRegistry
func (*DoApp) LegacyAmino ¶
func (app *DoApp) LegacyAmino() *codec.LegacyAmino
LegacyAmino returns DoApp's amino codec.
NOTE: This is solely to be used for testing purposes as it may be desirable for modules to register their own custom testing types.
func (*DoApp) LoadHeight ¶
LoadHeight loads a particular height
func (*DoApp) ModuleAccountAddrs ¶
ModuleAccountAddrs returns all the app's module account addresses.
func (*DoApp) PreBlocker ¶
func (app *DoApp) PreBlocker(ctx sdk.Context, _ *abci.RequestFinalizeBlock) (*sdk.ResponsePreBlock, error)
PreBlocker runs before BeginBlocker in v0.50 and allows modules like x/upgrade to make consensus parameter changes visible to the rest of the block.
func (*DoApp) RegisterAPIRoutes ¶
RegisterAPIRoutes registers all application module routes with the provided API server.
func (*DoApp) RegisterNodeService ¶
func (*DoApp) RegisterTendermintService ¶
RegisterTendermintService implements the Application.RegisterTendermintService method.
func (*DoApp) RegisterTxService ¶
RegisterTxService implements the Application.RegisterTxService method.
func (*DoApp) SimulationManager ¶
func (app *DoApp) SimulationManager() *module.SimulationManager
SimulationManager implements the SimulationApp interface
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.