keeper

package
v0.0.14 Latest Latest
Warning

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

Go to latest
Published: May 1, 2024 License: Apache-2.0 Imports: 17 Imported by: 22

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeriveIntermediateSender added in v0.0.5

func DeriveIntermediateSender(channel, originalSender, bech32Prefix string) (string, error)

DeriveIntermediateSender derives the sender address to be used when calling wasm hooks

func GeneratePacketAckValue added in v0.0.8

func GeneratePacketAckValue(packet channeltypes.Packet, contract string) ([]byte, error)

func GetPacketAckKey added in v0.0.8

func GetPacketAckKey(channel string, packetSequence uint64) []byte

func GetPacketCallbackKey added in v0.0.8

func GetPacketCallbackKey(channel string, packetSequence uint64) []byte

func NewMsgServerImpl added in v0.0.8

func NewMsgServerImpl(keeper Keeper) types.MsgServer

NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.

Types

type Keeper

type Keeper struct {
	ContractKeeper *wasmkeeper.PermissionedKeeper
	// contains filtered or unexported fields
}

func NewKeeper

func NewKeeper(
	storeKey storetypes.StoreKey,
	paramSpace paramtypes.Subspace,
	channelKeeper types.ChannelKeeper,
	contractKeeper *wasmkeeper.PermissionedKeeper,
) *Keeper

NewKeeper returns a new instance of the x/ibchooks keeper

func (Keeper) DeletePacketAckActor added in v0.0.8

func (k Keeper) DeletePacketAckActor(ctx sdk.Context, channel string, packetSequence uint64)

DeletePacketAckActor deletes the ack actor from storage once it has been used

func (Keeper) DeletePacketCallback

func (k Keeper) DeletePacketCallback(ctx sdk.Context, channel string, packetSequence uint64)

DeletePacketCallback deletes the callback from storage once it has been processed

func (Keeper) EmitIBCAck added in v0.0.8

func (k Keeper) EmitIBCAck(ctx sdk.Context, sender, channel string, packetSequence uint64) ([]byte, error)

EmitIBCAck emits an event that the IBC packet has been acknowledged

func (Keeper) ExportGenesis added in v0.0.8

func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState

func (Keeper) GetPacketAckActor added in v0.0.8

func (k Keeper) GetPacketAckActor(ctx sdk.Context, channel string, packetSequence uint64) (string, string)

GetPacketAckActor returns the bech32 addr of the contract that is allowed to send an ack for the packet and the packet hash

func (Keeper) GetPacketCallback

func (k Keeper) GetPacketCallback(ctx sdk.Context, channel string, packetSequence uint64) string

GetPacketCallback returns the bech32 addr of the contract that is expecting a callback from a packet

func (Keeper) GetParams added in v0.0.8

func (k Keeper) GetParams(ctx sdk.Context) (params types.Params)

GetParams returns the total set of the module's parameters.

func (Keeper) InitGenesis added in v0.0.8

func (k Keeper) InitGenesis(ctx sdk.Context, genState types.GenesisState)

func (Keeper) IsInAllowList added in v0.0.8

func (k Keeper) IsInAllowList(ctx sdk.Context, contract string) bool

IsInAllowList checks the params to see if the contract is in the KeyAsyncAckAllowList param

func (Keeper) Logger

func (k Keeper) Logger(ctx sdk.Context) log.Logger

Logger returns a logger for the x/tokenfactory module

func (Keeper) SetParam added in v0.0.10

func (k Keeper) SetParam(ctx sdk.Context, key []byte, value interface{})

SetParam sets a specific ibc-hooks module's parameter with the provided parameter.

func (Keeper) SetParams added in v0.0.8

func (k Keeper) SetParams(ctx sdk.Context, params types.Params)

SetParams sets the module's parameters with the provided parameters.

func (Keeper) StorePacketAckActor added in v0.0.8

func (k Keeper) StorePacketAckActor(ctx sdk.Context, packet channeltypes.Packet, contract string)

StorePacketAckActor stores which contract is allowed to send an ack for the packet

func (Keeper) StorePacketCallback

func (k Keeper) StorePacketCallback(ctx sdk.Context, channel string, packetSequence uint64, contract string)

StorePacketCallback stores which contract will be listening for the ack or timeout of a packet

Jump to

Keyboard shortcuts

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