Documentation ¶
Index ¶
- func NewMsgServerImpl(keeper *Keeper) types.MsgServer
- type BankHooks
- type Keeper
- func (k Keeper) BlockBeforeSend(ctx context.Context, from, to sdk.AccAddress, amount sdk.Coins) error
- func (k Keeper) DelegateCoins(ctx context.Context, delegatorAddr, moduleAccAddr sdk.AccAddress, ...) error
- func (k Keeper) DelegateCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, ...) error
- func (k Keeper) SendCoins(ctx context.Context, fromAddr, toAddr sdk.AccAddress, amt sdk.Coins) error
- func (k Keeper) SendCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, ...) error
- func (k Keeper) SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, ...) error
- func (k Keeper) SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt sdk.Coins) error
- func (k Keeper) SendCoinsWithoutBlockHook(ctx context.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, ...) error
- func (k *Keeper) SetHooks(bh BankHooks) *Keeper
- func (k Keeper) TrackBeforeSend(ctx context.Context, from, to sdk.AccAddress, amount sdk.Coins)
- func (k Keeper) UndelegateCoins(ctx context.Context, moduleAccAddr, delegatorAddr sdk.AccAddress, ...) error
- func (k Keeper) UndelegateCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the bank MsgServer interface for the provided Keeper.
Types ¶
type Keeper ¶
type Keeper struct { bankkeeper.BaseKeeper // contains filtered or unexported fields }
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, storeService store.KVStoreService, ak types.AccountKeeper, blockedAddrs map[string]bool, authority string, logger log.Logger, ) Keeper
func (Keeper) BlockBeforeSend ¶
func (k Keeper) BlockBeforeSend(ctx context.Context, from, to sdk.AccAddress, amount sdk.Coins) error
BlockBeforeSend executes the BlockBeforeSend hook if registered.
func (Keeper) DelegateCoins ¶
func (Keeper) DelegateCoinsFromAccountToModule ¶
func (k Keeper) DelegateCoinsFromAccountToModule( ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins, ) error
DelegateCoinsFromAccountToModule delegates coins and transfers them from a delegator account to a module account. It will panic if the module account does not exist or is unauthorized.
func (Keeper) SendCoinsFromAccountToModule ¶
func (k Keeper) SendCoinsFromAccountToModule( ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins, ) error
SendCoinsFromAccountToModule transfers coins from an AccAddress to a ModuleAccount. It will panic if the module account does not exist.
func (Keeper) SendCoinsFromModuleToAccount ¶
func (Keeper) SendCoinsFromModuleToModule ¶
func (k Keeper) SendCoinsFromModuleToModule( ctx context.Context, senderModule, recipientModule string, amt sdk.Coins, ) error
SendCoinsFromModuleToModule transfers coins from a ModuleAccount to another. It will panic if either module account does not exist. SendCoinsFromModuleToModule is the only send method that does not call both BlockBeforeSend and TrackBeforeSend hook. It only calls the TrackBeforeSend hook.
func (Keeper) SendCoinsWithoutBlockHook ¶
func (k Keeper) SendCoinsWithoutBlockHook(ctx context.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error
SendCoinsWithoutBlockHook calls sendCoins without calling the `BlockBeforeSend` hook.
func (Keeper) TrackBeforeSend ¶
TrackBeforeSend executes the TrackBeforeSend hook if registered.
func (Keeper) UndelegateCoins ¶
func (Keeper) UndelegateCoinsFromModuleToAccount ¶
func (k Keeper) UndelegateCoinsFromModuleToAccount( ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins, ) error
UndelegateCoinsFromModuleToAccount undelegates the unbonding coins and transfers them from a module account to the delegator account. It will panic if the module account does not exist or is unauthorized.