2020-04-01 18:49:21 +00:00
|
|
|
package types
|
|
|
|
|
|
|
|
import (
|
|
|
|
sdk "github.com/cosmos/cosmos-sdk/types"
|
|
|
|
authexported "github.com/cosmos/cosmos-sdk/x/auth/exported"
|
|
|
|
)
|
|
|
|
|
|
|
|
// AccountKeeper defines the expected account keeper interface
|
|
|
|
type AccountKeeper interface {
|
|
|
|
NewAccountWithAddress(ctx sdk.Context, addr sdk.AccAddress) authexported.Account
|
2020-05-18 19:21:12 +00:00
|
|
|
GetAllAccounts(ctx sdk.Context) (accounts []authexported.Account)
|
2020-04-01 18:49:21 +00:00
|
|
|
GetAccount(ctx sdk.Context, addr sdk.AccAddress) authexported.Account
|
|
|
|
SetAccount(ctx sdk.Context, account authexported.Account)
|
|
|
|
RemoveAccount(ctx sdk.Context, account authexported.Account)
|
|
|
|
}
|
2020-04-22 19:26:01 +00:00
|
|
|
|
|
|
|
// BankKeeper defines the expected interface needed to retrieve account balances.
|
|
|
|
type BankKeeper interface {
|
|
|
|
GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin
|
|
|
|
SetBalance(ctx sdk.Context, addr sdk.AccAddress, balance sdk.Coin) error
|
|
|
|
}
|