cosmos-sdk: Index | Files

package keeper

import ""


Package Files


type Keeper Uses

type Keeper struct {
    // contains filtered or unexported fields

Keeper defines the IBC connection keeper

func NewKeeper Uses

func NewKeeper(sck capabilitykeeper.ScopedKeeper) Keeper

NewKeeper creates a new IBC connection Keeper instance

func (Keeper) Authenticate Uses

func (k Keeper) Authenticate(ctx sdk.Context, key *capabilitytypes.Capability, portID string) bool

Authenticate authenticates a capability key against a port ID by checking if the memory address of the capability was previously generated and bound to the port (provided as a parameter) which the capability is being authenticated against.

func (*Keeper) BindPort Uses

func (k *Keeper) BindPort(ctx sdk.Context, portID string) *capabilitytypes.Capability

BindPort binds to a port and returns the associated capability. Ports must be bound statically when the chain starts in `app.go`. The capability must then be passed to a module which will need to pass it as an extra parameter when calling functions on the IBC module.

func (Keeper) Logger Uses

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

Logger returns a module-specific logger.

func (Keeper) LookupModuleByPort Uses

func (k Keeper) LookupModuleByPort(ctx sdk.Context, portID string) (string, *capabilitytypes.Capability, error)

LookupModuleByPort will return the IBCModule along with the capability associated with a given portID

Package keeper imports 7 packages (graph) and is imported by 1 packages. Updated 2020-08-01. Refresh now. Tools for package owners.