Documentation ¶
Index ¶
- type Keeper
- func (k Keeper) OnRecvPacket(ctx sdk.Context, packet channeltypes.Packet, ...) error
- func (k Keeper) PostOnRecvPacket(ctx sdk.Context, packet channeltypes.Packet, ...)
- func (k Keeper) SendTransfer(ctx sdk.Context, sourcePort, sourceChannel string, token sdk.Coin, ...) error
- func (k Keeper) TrackDenomMetadata(ctx sdk.Context, denomTrace ibctransfertypes.DenomTrace)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Keeper ¶
type Keeper struct { // embed the ICS-20 transfer keeper ibctransferkeeper.Keeper // contains filtered or unexported fields }
Keeper embeds the ICS-20 transfer keeper where we only override specific methods.
func New ¶
func New(tk ibctransferkeeper.Keeper, bk types.BankKeeper) Keeper
func (Keeper) OnRecvPacket ¶
func (k Keeper) OnRecvPacket( ctx sdk.Context, packet channeltypes.Packet, data ibctransfertypes.FungibleTokenPacketData, ) error
OnRecvPacket delegates the OnRecvPacket call to the embedded ICS-20 transfer module and updates metadata if successful.
func (Keeper) PostOnRecvPacket ¶
func (k Keeper) PostOnRecvPacket( ctx sdk.Context, packet channeltypes.Packet, data ibctransfertypes.FungibleTokenPacketData, )
PostOnRecvPacket executes arbitrary logic after a successful OnRecvPacket call. Currently, it checks and adds denomination metadata upon receiving an IBC asset.
func (Keeper) SendTransfer ¶
func (k Keeper) SendTransfer( ctx sdk.Context, sourcePort, sourceChannel string, token sdk.Coin, sender sdk.AccAddress, receiver string, timeoutHeight clienttypes.Height, timeoutTimestamp uint64, ) error
SendTransfer delegates the SendTransfer call to the embedded ICS-20 transfer module and updates metadata if successful.
func (Keeper) TrackDenomMetadata ¶
func (k Keeper) TrackDenomMetadata(ctx sdk.Context, denomTrace ibctransfertypes.DenomTrace)
TrackDenomMetadata checks for the metadata existence of an IBC transferred asset and if it does not exist, it attempts to add it. Note, we cannot infer the exponent or any units so we default to zero.