types

package
v0.3.7 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ModuleCdc = codec.New()

ModuleCdc defines module codec

Functions

func RegisterCodec

func RegisterCodec(cdc *codec.Codec)

RegisterCodec registers all the necessary types and interfaces for governance.

func RegisterProposalTypeCodec

func RegisterProposalTypeCodec(o interface{}, name string)

RegisterProposalTypeCodec registers an external proposal content type defined in another module for the internal ModuleCdc. This allows the MsgSubmitProposal to be correctly Amino encoded and decoded.

Types

type SupplyKeeper

type SupplyKeeper interface {
	GetModuleAddress(name string) sdk.AccAddress
	GetModuleAccount(ctx sdk.Context, name string) supply.ModuleAccountI

	// TODO remove with genesis 2-phases refactor https://github.com/cosmos/cosmos-sdk/issues/2862
	SetModuleAccount(sdk.Context, supply.ModuleAccountI)

	SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) sdk.Error
	SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) sdk.Error
	BurnCoins(ctx sdk.Context, name string, amt sdk.Coins) sdk.Error
}

SupplyKeeper defines the supply Keeper for module accounts

Jump to

Keyboard shortcuts

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