Documentation
¶
Index ¶
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- type Keeper
- func (k Keeper) CreateClobPair(ctx sdk.Context, perpetualId uint32) (clobPairId uint32, err error)
- func (k Keeper) CreateMarket(ctx sdk.Context, ticker string) (marketId uint32, err error)
- func (k Keeper) CreatePerpetual(ctx sdk.Context, marketId uint32, ticker string) (perpetualId uint32, err error)
- func (k Keeper) DepositToMegavaultforPML(ctx sdk.Context, fromSubaccount satypes.SubaccountId, clobPairId uint32) error
- func (k Keeper) GetIndexerEventManager() indexer_manager.IndexerEventManager
- func (k Keeper) GetListingVaultDepositParams(ctx sdk.Context) (vaultDepositParams types.ListingVaultDepositParams)
- func (k Keeper) GetMarketsHardCap(ctx sdk.Context) (hardCap uint32)
- func (k Keeper) HasAuthority(authority string) bool
- func (k Keeper) InitializeForGenesis(ctx sdk.Context)
- func (k Keeper) ListingVaultDepositParams(ctx context.Context, req *types.QueryListingVaultDepositParams) (*types.QueryListingVaultDepositParamsResponse, error)
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) MarketsHardCap(ctx context.Context, req *types.QueryMarketsHardCap) (*types.QueryMarketsHardCapResponse, error)
- func (k Keeper) SetListingVaultDepositParams(ctx sdk.Context, params types.ListingVaultDepositParams) error
- func (k Keeper) SetMarketsHardCap(ctx sdk.Context, hardCap uint32) error
- func (k Keeper) UpgradeIsolatedPerpetualToCross(ctx sdk.Context, perpetualId uint32) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.
Types ¶
type Keeper ¶
type Keeper struct {
PricesKeeper types.PricesKeeper
ClobKeeper types.ClobKeeper
MarketMapKeeper types.MarketMapKeeper
PerpetualsKeeper types.PerpetualsKeeper
SubaccountsKeeper types.SubaccountsKeeper
VaultKeeper types.VaultKeeper
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, storeKey storetypes.StoreKey, authorities []string, indexerEventsManager indexer_manager.IndexerEventManager, pricesKeeper types.PricesKeeper, clobKeeper types.ClobKeeper, marketMapKeeper types.MarketMapKeeper, perpetualsKeeper types.PerpetualsKeeper, subaccountsKeeper types.SubaccountsKeeper, vaultKeeper types.VaultKeeper, ) *Keeper
func (Keeper) CreateClobPair ¶
func (k Keeper) CreateClobPair( ctx sdk.Context, perpetualId uint32, ) (clobPairId uint32, err error)
Function to wrap the creation of a new clob pair Note: This will only list long-tail/isolated markets
func (Keeper) CreateMarket ¶
Function to wrap the creation of a new market Note: This will only list long-tail/isolated markets
func (Keeper) CreatePerpetual ¶
func (k Keeper) CreatePerpetual( ctx sdk.Context, marketId uint32, ticker string, ) (perpetualId uint32, err error)
Function to wrap the creation of a new perpetual Note: This will only list long-tail/isolated markets
func (Keeper) DepositToMegavaultforPML ¶
func (k Keeper) DepositToMegavaultforPML( ctx sdk.Context, fromSubaccount satypes.SubaccountId, clobPairId uint32, ) error
Function to deposit to the megavault for a new PML market This function deposits money to the megavault, transfers the new vault deposit amount to the new market vault and locks the shares for the deposit
func (Keeper) GetIndexerEventManager ¶
func (k Keeper) GetIndexerEventManager() indexer_manager.IndexerEventManager
func (Keeper) GetListingVaultDepositParams ¶
func (k Keeper) GetListingVaultDepositParams( ctx sdk.Context, ) (vaultDepositParams types.ListingVaultDepositParams)
Function to get listing vault deposit params from module store
func (Keeper) GetMarketsHardCap ¶
Function to get hard cap on listed markets from module store
func (Keeper) HasAuthority ¶
func (Keeper) InitializeForGenesis ¶
func (Keeper) ListingVaultDepositParams ¶
func (k Keeper) ListingVaultDepositParams( ctx context.Context, req *types.QueryListingVaultDepositParams, ) (*types.QueryListingVaultDepositParamsResponse, error)
func (Keeper) MarketsHardCap ¶
func (k Keeper) MarketsHardCap( ctx context.Context, req *types.QueryMarketsHardCap, ) (*types.QueryMarketsHardCapResponse, error)
func (Keeper) SetListingVaultDepositParams ¶
func (k Keeper) SetListingVaultDepositParams( ctx sdk.Context, params types.ListingVaultDepositParams, ) error
Function to set listing vault deposit params in module store
func (Keeper) SetMarketsHardCap ¶
Function to set hard cap on listed markets in module store