swingset

package
v0.0.0-...-99ea1f7 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2020 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModuleName = types.ModuleName
	RouterKey  = types.RouterKey
	StoreKey   = types.StoreKey
)

Variables

View Source
var (
	NewKeeper            = keeper.NewKeeper
	NewQuerier           = keeper.NewQuerier
	NewMsgDeliverInbound = types.NewMsgDeliverInbound
	NewMsgProvision      = types.NewMsgProvision
	NewMsgSendPacket     = types.NewMsgSendPacket
	NewStorage           = types.NewStorage
	NewMailbox           = types.NewMailbox
	NewKeys              = types.NewKeys
	ModuleCdc            = types.ModuleCdc
	RegisterCodec        = types.RegisterCodec
)

Functions

func BeginBlock

func BeginBlock(ctx sdk.Context, req abci.RequestBeginBlock, keeper Keeper) error

func CommitBlock

func CommitBlock(keeper Keeper) error

func EndBlock

func EndBlock(ctx sdk.Context, req abci.RequestEndBlock, keeper Keeper) ([]abci.ValidatorUpdate, error)

func GetPort

func GetPort(name string) int

func InitGenesis

func InitGenesis(ctx sdk.Context, keeper Keeper, data GenesisState) []abci.ValidatorUpdate

func NewHandler

func NewHandler(keeper Keeper) sdk.Handler

NewHandler returns a handler for "swingset" type messages.

func NewIBCChannelHandler

func NewIBCChannelHandler(ibcModule porttypes.IBCModule) channelHandler

func NewStorageHandler

func NewStorageHandler() storageHandler

func ReceiveFromController

func ReceiveFromController(portNum int, msg string) (string, error)

func RegisterPortHandler

func RegisterPortHandler(name string, portHandler PortHandler) int

func SetControllerContext

func SetControllerContext(ctx sdk.Context) func()

func SetControllerKeeper

func SetControllerKeeper(keeper *Keeper) func()

func UnregisterPortHandler

func UnregisterPortHandler(portNum int) error

func ValidateGenesis

func ValidateGenesis(data GenesisState) error

Types

type AppModule

type AppModule struct {
	AppModuleBasic
	// contains filtered or unexported fields
}

func NewAppModule

func NewAppModule(k Keeper) AppModule

NewAppModule creates a new AppModule Object

func (AppModule) BeginBlock

func (am AppModule) BeginBlock(ctx sdk.Context, req abci.RequestBeginBlock)

func (AppModule) CallToController

func (am AppModule) CallToController(ctx sdk.Context, send string) (string, error)

func (AppModule) EndBlock

func (am AppModule) EndBlock(ctx sdk.Context, req abci.RequestEndBlock) []abci.ValidatorUpdate

func (AppModule) ExportGenesis

func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONMarshaler) json.RawMessage

func (AppModule) InitGenesis

func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONMarshaler, data json.RawMessage) []abci.ValidatorUpdate

func (AppModule) Name

func (AppModule) Name() string

func (AppModule) NewHandler

func (am AppModule) NewHandler() sdk.Handler

func (AppModule) NewQuerierHandler

func (am AppModule) NewQuerierHandler() sdk.Querier

func (AppModule) OnAcknowledgementPacket

func (am AppModule) OnAcknowledgementPacket(
	ctx sdk.Context,
	packet channeltypes.Packet,
	acknowledgement []byte,
) (*sdk.Result, error)

func (AppModule) OnChanCloseConfirm

func (am AppModule) OnChanCloseConfirm(
	ctx sdk.Context,
	portID,
	channelID string,
) error

func (AppModule) OnChanCloseInit

func (am AppModule) OnChanCloseInit(
	ctx sdk.Context,
	portID,
	channelID string,
) error

func (AppModule) OnChanOpenAck

func (am AppModule) OnChanOpenAck(
	ctx sdk.Context,
	portID,
	channelID string,
	counterpartyVersion string,
) error

func (AppModule) OnChanOpenConfirm

func (am AppModule) OnChanOpenConfirm(
	ctx sdk.Context,
	portID,
	channelID string,
) error

func (AppModule) OnChanOpenInit

func (am AppModule) OnChanOpenInit(
	ctx sdk.Context,
	order ibctypes.Order,
	connectionHops []string,
	portID string,
	channelID string,
	channelCap *capability.Capability,
	counterparty channeltypes.Counterparty,
	version string,
) error

Implement IBCModule callbacks

func (AppModule) OnChanOpenTry

func (am AppModule) OnChanOpenTry(
	ctx sdk.Context,
	order ibctypes.Order,
	connectionHops []string,
	portID,
	channelID string,
	channelCap *capability.Capability,
	counterparty channeltypes.Counterparty,
	version,
	counterpartyVersion string,
) error

func (AppModule) OnRecvPacket

func (am AppModule) OnRecvPacket(
	ctx sdk.Context,
	packet channeltypes.Packet,
) (*sdk.Result, error)

func (AppModule) OnTimeoutPacket

func (am AppModule) OnTimeoutPacket(
	ctx sdk.Context,
	packet channeltypes.Packet,
) (*sdk.Result, error)

func (AppModule) QuerierRoute

func (am AppModule) QuerierRoute() string

func (AppModule) RegisterInvariants

func (am AppModule) RegisterInvariants(ir sdk.InvariantRegistry)

func (AppModule) Route

func (am AppModule) Route() string

type AppModuleBasic

type AppModuleBasic struct{}

app module Basics object

func (AppModuleBasic) DefaultGenesis

func (AppModuleBasic) DefaultGenesis(cdc codec.JSONMarshaler) json.RawMessage

func (AppModuleBasic) GetQueryCmd

func (AppModuleBasic) GetQueryCmd(cdc *codec.Codec) *cobra.Command

Get the root query command of this module

func (AppModuleBasic) GetTxCmd

func (AppModuleBasic) GetTxCmd(cdc *codec.Codec) *cobra.Command

Get the root tx command of this module

func (AppModuleBasic) Name

func (AppModuleBasic) Name() string

func (AppModuleBasic) RegisterCodec

func (AppModuleBasic) RegisterCodec(cdc *codec.Codec)

func (AppModuleBasic) RegisterRESTRoutes

func (AppModuleBasic) RegisterRESTRoutes(ctx context.CLIContext, rtr *mux.Router)

Register rest routes

func (AppModuleBasic) ValidateGenesis

func (AppModuleBasic) ValidateGenesis(cdc codec.JSONMarshaler, bz json.RawMessage) error

Validation check of the Genesis

type ControllerContext

type ControllerContext struct {
	Keeper                *Keeper
	Context               sdk.Context
	StoragePort           int
	IBCChannelHandlerPort int
}

type DefaultRouter

type DefaultRouter struct {
	*port.Router
	// contains filtered or unexported fields
}

DefaultRouter is a temporary hack until cosmos-sdk implements its features FIXME.

type Egress

type Egress = types.Egress

type GenesisState

type GenesisState struct {
	// TODO: Provisioning records
	Egresses []types.Egress `json:"egresses"`
}

func DefaultGenesisState

func DefaultGenesisState() GenesisState

func ExportGenesis

func ExportGenesis(ctx sdk.Context, k Keeper) GenesisState

func NewGenesisState

func NewGenesisState() GenesisState

type Keeper

type Keeper = keeper.Keeper

type MsgDeliverInbound

type MsgDeliverInbound = types.MsgDeliverInbound

type MsgProvision

type MsgProvision = types.MsgProvision

type MsgSendPacket

type MsgSendPacket = types.MsgSendPacket

type PortHandler

type PortHandler interface {
	Receive(*ControllerContext, string) (string, error)
}

type QueryResKeys

type QueryResKeys = types.QueryResKeys

type QueryResStorage

type QueryResStorage = types.QueryResStorage

type Storage

type Storage = types.Storage

Directories

Path Synopsis
client
cli
internal

Jump to

Keyboard shortcuts

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