market

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2019 License: Apache-2.0, Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	QueryList = "list"
)

Variables

This section is empty.

Functions

func InitGenesis

func InitGenesis(ctx sdk.Context, keeper Keeper, data GenesisState)

func NewHandler

func NewHandler(k Keeper) sdk.Handler

func NewQuerier

func NewQuerier(keeper Keeper) sdk.Querier

func ValidateGenesis

func ValidateGenesis(data GenesisState) error

Types

type AppModule

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

AppModule implements an application module for the crisis module.

func NewAppModule

func NewAppModule(keeper Keeper) AppModule

NewAppModule creates a new AppModule object

func (AppModule) BeginBlock

func (a AppModule) BeginBlock(sdk.Context, abci.RequestBeginBlock)

func (AppModule) EndBlock

func (AppModule) ExportGenesis

func (a AppModule) ExportGenesis(ctx sdk.Context) json.RawMessage

func (AppModule) InitGenesis

func (a AppModule) InitGenesis(ctx sdk.Context, data json.RawMessage) []abci.ValidatorUpdate

func (AppModule) NewHandler

func (a AppModule) NewHandler() sdk.Handler

func (AppModule) NewQuerierHandler

func (a AppModule) NewQuerierHandler() sdk.Querier

func (AppModule) QuerierRoute

func (a AppModule) QuerierRoute() string

func (AppModule) RegisterInvariants

func (a AppModule) RegisterInvariants(sdk.InvariantRegistry)

func (AppModule) Route

func (a AppModule) Route() string

type AppModuleBasic

type AppModuleBasic struct{}

AppModuleBasic defines the basic application module used by the market module.

func (AppModuleBasic) DefaultGenesis

func (a AppModuleBasic) DefaultGenesis() json.RawMessage

func (AppModuleBasic) GetQueryCmd

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

func (AppModuleBasic) GetTxCmd

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

func (AppModuleBasic) Name

func (a AppModuleBasic) Name() string

func (AppModuleBasic) RegisterCodec

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

func (AppModuleBasic) RegisterRESTRoutes

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

func (AppModuleBasic) ValidateGenesis

func (a AppModuleBasic) ValidateGenesis(b json.RawMessage) error

type GenesisState

type GenesisState struct {
	Markets []types.Market
}

func DefaultGenesisState

func DefaultGenesisState() GenesisState

func ExportGenesis

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

func NewGenesisState

func NewGenesisState(markets []types.Market) GenesisState

type IteratorCB

type IteratorCB func(mkt types.Market) bool

type Keeper

type Keeper struct {
	// contains filtered or unexported fields
}

func NewKeeper

func NewKeeper(sk sdk.StoreKey, ak asset.Keeper, cdc *codec.Codec) Keeper

func (Keeper) Create

func (k Keeper) Create(ctx sdk.Context, baseAsset store.EntityID, quoteAsset store.EntityID) types.Market

func (Keeper) Get

func (k Keeper) Get(ctx sdk.Context, id store.EntityID) (types.Market, sdk.Error)

func (Keeper) Has

func (k Keeper) Has(ctx sdk.Context, id store.EntityID) bool

func (Keeper) Inject

func (k Keeper) Inject(ctx sdk.Context, market types.Market)

func (Keeper) Iterator

func (k Keeper) Iterator(ctx sdk.Context, cb IteratorCB)

func (Keeper) Pair

func (k Keeper) Pair(ctx sdk.Context, id store.EntityID) (string, sdk.Error)

Directories

Path Synopsis
client
cli

Jump to

Keyboard shortcuts

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