-
Notifications
You must be signed in to change notification settings - Fork 197
/
expected_keepers.go
29 lines (25 loc) · 1.25 KB
/
expected_keepers.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
package types
import (
sdk "github.com/cosmos/cosmos-sdk/types"
capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types"
channeltypes "github.com/cosmos/ibc-go/v5/modules/core/04-channel/types"
"github.com/cosmos/ibc-go/v5/modules/core/exported"
ibcexported "github.com/cosmos/ibc-go/v5/modules/core/exported"
)
// BankKeeper defines the banking contract that must be fulfilled when
// creating a x/ratelimit keeper.
type BankKeeper interface {
GetSupply(ctx sdk.Context, denom string) sdk.Coin
}
// ChannelKeeper defines the channel contract that must be fulfilled when
// creating a x/ratelimit keeper.
type ChannelKeeper interface {
GetChannel(ctx sdk.Context, portID string, channelID string) (channeltypes.Channel, bool)
GetChannelClientState(ctx sdk.Context, portID string, channelID string) (string, exported.ClientState, error)
}
// ICS4Wrapper defines the expected ICS4Wrapper for middleware
type ICS4Wrapper interface {
WriteAcknowledgement(ctx sdk.Context, chanCap *capabilitytypes.Capability, packet ibcexported.PacketI, acknowledgement ibcexported.Acknowledgement) error
SendPacket(ctx sdk.Context, channelCap *capabilitytypes.Capability, packet ibcexported.PacketI) error
GetAppVersion(ctx sdk.Context, portID, channelID string) (string, bool)
}