Documentation ¶
Index ¶
Constants ¶
const ( ModuleName = "dex" ProductsPath = "custom/dex/products" )
const
Variables ¶
This section is empty.
Functions ¶
func RegisterCodec ¶
RegisterCodec registers the msg type for dex module
Types ¶
type MsgCreateOperator ¶ added in v0.11.0
type MsgCreateOperator struct { Owner sdk.AccAddress `json:"owner"` Website string `json:"website"` HandlingFeeAddress sdk.AccAddress `json:"handling_fee_address"` }
MsgCreateOperator - structure to register a new DEXOperator or update it
func NewMsgCreateOperator ¶ added in v0.11.0
func NewMsgCreateOperator(owner, handlingFeeAddress sdk.AccAddress, website string) MsgCreateOperator
NewMsgCreateOperator creates a new MsgCreateOperator
func (MsgCreateOperator) GetSignBytes ¶ added in v0.11.0
func (msg MsgCreateOperator) GetSignBytes() []byte
GetSignBytes encodes the message for signing
func (MsgCreateOperator) GetSigners ¶ added in v0.11.0
func (MsgCreateOperator) GetSigners() []sdk.AccAddress
func (MsgCreateOperator) Type ¶ added in v0.11.0
func (MsgCreateOperator) Type() string
func (MsgCreateOperator) ValidateBasic ¶ added in v0.11.0
func (MsgCreateOperator) ValidateBasic() sdk.Error
type MsgDeposit ¶
type MsgDeposit struct { Product string `json:"product"` Amount sdk.DecCoin `json:"amount"` Depositor sdk.AccAddress `json:"depositor"` }
MsgDeposit - structure for depositing on a product
func NewMsgDeposit ¶
func NewMsgDeposit(depositor sdk.AccAddress, product string, amount sdk.DecCoin) MsgDeposit
NewMsgDeposit creates a msg of depositing
func (MsgDeposit) GetSignBytes ¶
func (msg MsgDeposit) GetSignBytes() []byte
GetSignBytes encodes the message for signing
func (MsgDeposit) GetSigners ¶
func (MsgDeposit) GetSigners() []sdk.AccAddress
func (MsgDeposit) Type ¶
func (MsgDeposit) Type() string
func (MsgDeposit) ValidateBasic ¶
func (MsgDeposit) ValidateBasic() sdk.Error
type MsgList ¶
type MsgList struct { Owner sdk.AccAddress `json:"owner"` ListAsset string `json:"list_asset"` QuoteAsset string `json:"quote_asset"` InitPrice sdk.Dec `json:"init_price"` }
MsgList - structure for listing a trading pair on dex
func NewMsgList ¶
NewMsgList creates a msg of listing a trading pair on dex
func (MsgList) GetSignBytes ¶
GetSignBytes encodes the message for signing
func (MsgList) GetSigners ¶
func (MsgList) GetSigners() []sdk.AccAddress
func (MsgList) ValidateBasic ¶
type MsgTransferOwnership ¶
type MsgTransferOwnership struct { FromAddress sdk.AccAddress `json:"from_address"` ToAddress sdk.AccAddress `json:"to_address"` Product string `json:"product"` ToSignature sdk.StdSignature `json:"to_signature"` }
MsgTransferOwnership - structure to change the owner of the product
func NewMsgTransferOwnership ¶
func NewMsgTransferOwnership(fromAddr, toAddr sdk.AccAddress, product string) MsgTransferOwnership
NewMsgTransferOwnership creates a msg of changing product's owner
func (MsgTransferOwnership) GetSignBytes ¶
func (msg MsgTransferOwnership) GetSignBytes() []byte
GetSignBytes encodes the message for signing
func (MsgTransferOwnership) GetSigners ¶
func (MsgTransferOwnership) GetSigners() []sdk.AccAddress
func (MsgTransferOwnership) Type ¶
func (MsgTransferOwnership) Type() string
func (MsgTransferOwnership) ValidateBasic ¶
func (MsgTransferOwnership) ValidateBasic() sdk.Error
type MsgUpdateOperator ¶ added in v0.11.0
type MsgUpdateOperator struct { Owner sdk.AccAddress `json:"owner"` Website string `json:"website"` HandlingFeeAddress sdk.AccAddress `json:"handling_fee_address"` }
MsgUpdateOperator - structure to update an existed DEXOperator
func NewMsgUpdateOperator ¶ added in v0.11.0
func NewMsgUpdateOperator(owner, handlingFeeAddress sdk.AccAddress, website string) MsgUpdateOperator
NewMsgUpdateOperator creates a new MsgUpdateOperator
func (MsgUpdateOperator) GetSignBytes ¶ added in v0.11.0
func (msg MsgUpdateOperator) GetSignBytes() []byte
GetSignBytes encodes the message for signing
func (MsgUpdateOperator) GetSigners ¶ added in v0.11.0
func (MsgUpdateOperator) GetSigners() []sdk.AccAddress
func (MsgUpdateOperator) Type ¶ added in v0.11.0
func (MsgUpdateOperator) Type() string
func (MsgUpdateOperator) ValidateBasic ¶ added in v0.11.0
func (MsgUpdateOperator) ValidateBasic() sdk.Error
type MsgWithdraw ¶
type MsgWithdraw struct { Product string `json:"product"` Amount sdk.DecCoin `json:"amount"` Depositor sdk.AccAddress `json:"depositor"` }
MsgWithdraw - structure for withdrawing from a product
func NewMsgWithdraw ¶
func NewMsgWithdraw(depositor sdk.AccAddress, product string, amount sdk.DecCoin) MsgWithdraw
NewMsgWithdraw creates a msg of withdrawing
func (MsgWithdraw) GetSignBytes ¶
func (msg MsgWithdraw) GetSignBytes() []byte
GetSignBytes encodes the message for signing
func (MsgWithdraw) GetSigners ¶
func (MsgWithdraw) GetSigners() []sdk.AccAddress
func (MsgWithdraw) Type ¶
func (MsgWithdraw) Type() string
func (MsgWithdraw) ValidateBasic ¶
func (MsgWithdraw) ValidateBasic() sdk.Error
type TokenPair ¶
type TokenPair struct { BaseAssetSymbol string `json:"base_asset_symbol"` QuoteAssetSymbol string `json:"quote_asset_symbol"` InitPrice sdk.Dec `json:"price"` MaxPriceDigit int64 `json:"max_price_digit"` MaxQuantityDigit int64 `json:"max_size_digit"` MinQuantity sdk.Dec `json:"min_trade_size"` ID uint64 `json:"token_pair_id"` Delisting bool `json:"delisting"` Owner sdk.AccAddress `json:"owner"` Deposits sdk.DecCoin `json:"deposits"` BlockHeight int64 `json:"block_height"` }
TokenPair represents token pair object