types

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2021 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EventTypeDisburse           = "disburse"
	EventTypeDisburseToEscrow   = "disburse_to_escrow"
	EventTypeDisburseFromEscrow = "disburse_from_escrow"
	EventTypeRevertFromEscrow   = "revert_from_escrow"
	EventTypeAddOperator        = "add_operator"
	EventTypeRemoveOperator     = "remove_operator"
	EventTypeCancelDisbursement = "cancel_disbursement"
	EventTypeCreateSellOrder    = "create_sell_order"
	EventTypeCreateBuyOrder     = "create_buy_order"
	EventTypeTransfer           = "transfer_to_distribution_module"
	EventTypeSwap               = "swap"

	EventTypeAddBuyBackLiquidity                               = "AddBuyBackLiquidity"
	EventTypeRemoveBuyBackLiquidity                            = "RemoveBuyBackLiquidity"
	EventTypeBurnDistributionProfits                           = "BurnDistributionProfits"
	EventTypeTransferFromDistributionProfitsToBuyBackLiquidity = "TransferFromDistributionProfitsToBuyBackLiquidity"
	EventTypeTransferFromTreasuryToSwapEscrow                  = "TransferFromTreasuryToSwapEscrow"
	EventTypeTransferSwapEscrowToBuyBack                       = "TransferSwapEscrowToBuyBack"

	AttributeKeySender          = "sender"
	AttributeKeyRecipient       = "recipient"
	AttributeKeyAmount          = "amount"
	AttributeKeyReference       = "reference"
	AttributeKeyScheduledFor    = "scheduledFor"
	AttributeKeyOperator        = "operator"
	AttributeKeyPinAmount       = "pin_amount"
	AttributeKeyDinAmount       = "din_amount"
	AttributeKeyEscrowRemainder = "escrow_remainder"
	AttributeKeyTitle           = "title"
	AttributeKeyDescription     = "description"

	AttributeValueModule = ModuleName
)
View Source
const (
	// ModuleName is the name of the module
	ModuleName = "treasury" // Module stores initial supply of Anatha

	// StoreKey to be used when creating the KVStore
	StoreKey = ModuleName

	// RouterKey to be used for routing msgs
	RouterKey = ModuleName

	// QuerierRoute to be used for querierer msgs
	QuerierRoute = ModuleName

	BuyBackLiquidityFundModuleName = "buyback_liquidity"    // Module stores the supply of AST for executing BuyBacks
	BuyBackFundModuleName          = "treasury_buyback"     // Module stores the bought back supply of Anatha (participates in distribution)
	DistributionProfitsModuleName  = "distribution_profits" // Module stores AST profits from Anatha purchases with AST
	TreasuryEscrowModuleName       = "treasury_escrow"      // Module stores distributions without supplied recipient addresses
	SwapEscrowModuleName           = "swap_escrow"          // Module stores ERC20 token balance
)
View Source
const (
	DefaultParamspace = ModuleName

	DefaultRiskAssesmentDuration = time.Hour * 24 * 3 // devnet: time.Second * 60 * 2
	DefaultRiskAssesmentAmount   = 10000              // usd
)
View Source
const (
	ProposalTypeAddBuyBackLiquidity                               = "AddBuyBackLiquidity"
	ProposalTypeRemoveBuyBackLiquidity                            = "RemoveBuyBackLiquidity"
	ProposalTypeBurnDistributionProfits                           = "BurnDistributionProfits"
	ProposalTypeTransferFromDistributionProfitsToBuyBackLiquidity = "TransferFromDistributionProfitsToBuyBackLiquidity"
	ProposalTypeTransferFromTreasuryToSwapEscrow                  = "TransferFromTreasuryToSwapEscrow"
	ProposalTypeTransferSwapEscrowToBuyBack                       = "TransferSwapEscrowToBuyBack"
)

Variables

View Source
var (
	ErrNotManager                       = sdkerrors.Register(ModuleName, 101, "No Manager permissions to execute the action.")
	ErrNotOperator                      = sdkerrors.Register(ModuleName, 102, "No Operator permissions to execute the action.")
	ErrInvalidTime                      = sdkerrors.Register(ModuleName, 103, "Invalid time")
	ErrEscrowDistributionAmountExceeded = sdkerrors.Register(ModuleName, 109, "escrow distribution amount exceeded")
	ErrInvalidReference                 = sdkerrors.Register(ModuleName, 110, "Invalid reference")
	ErrEscrowDisbursed                  = sdkerrors.Register(ModuleName, 111, "Escrow already disbursed")
	ErrDuplicateReference               = sdkerrors.Register(ModuleName, 112, "Reference already used")
	ErrEscrowRevertAmountTooBig         = sdkerrors.Register(ModuleName, 113, "Escrow revert amount too big")
	ErrDisbursementNotScheduled         = sdkerrors.Register(ModuleName, 114, "Disbursement not scheduled")
)
View Source
var (
	TreasuryKey = []byte{0x00}

	OperatorKeyPrefix          = []byte{0x10}
	DisbursementQueueKeyPrefix = []byte{0x12}

	DisbursementReferenceKeyPrefix = []byte{0x15}

	StatusPresent = []byte{0x01}
)
View Source
var (
	KeyManagers               = []byte("Managers")
	KeyRiskAssessmentAmount   = []byte("RiskAssesmentAmount")
	KeyRiskAssessmentDuration = []byte("RiskAssesmentDuration")
	KeyBuyBackPercentage      = []byte("BuyBackPercentage")

	DefaultManagerAddress = "anatha1qaf2gssp652s6np00a5cxdwytdf3vutdumwc0q"

	DefaultBuyBackPercentage = sdk.NewDecWithPrec(24, 2)
)
View Source
var (
	DefaultOperatorsList = []string{
		"anatha18klyq6qxyemrgsuyapw80y7xz4gh0lhjk9tj7n",
		"anatha1lafvzw2f6nj4sv2k0cpsu4zdxur9l0e98ngzxz",
		"anatha13fsp5p3mjcxtr833vcln6kjwvyl8tz66tu2j8z",
	}
)
View Source
var ModuleCdc = codec.New()

ModuleCdc defines the module codec

Functions

func DefaultOperators

func DefaultOperators() []sdk.AccAddress

func DisbursementByTimeKey

func DisbursementByTimeKey(endTime time.Time) []byte

func DisbursementQueueKey

func DisbursementQueueKey(address sdk.AccAddress, endTime time.Time) []byte

func GetDisbursementReferenceIteratorKey

func GetDisbursementReferenceIteratorKey() []byte

func GetDisbursementReferenceKey

func GetDisbursementReferenceKey(reference string) []byte

func GetOperatorIteratorKey

func GetOperatorIteratorKey() []byte

func GetOperatorKey

func GetOperatorKey(address sdk.AccAddress) []byte

func NewAddBuyBackLiquidityProposal

func NewAddBuyBackLiquidityProposal(title, description string, amount sdk.Coins) gov.Content

func NewBurnDistributionProfitsProposal

func NewBurnDistributionProfitsProposal(title, description string, amount sdk.Coins) gov.Content

func NewRemoveBuyBackLiquidityProposal

func NewRemoveBuyBackLiquidityProposal(title, description string, amount sdk.Coins) gov.Content

func NewTransferFromDistributionProfitsToBuyBackLiquidityProposal

func NewTransferFromDistributionProfitsToBuyBackLiquidityProposal(title, description string, amount sdk.Coins) gov.Content

func NewTransferFromSwapEscrowToBuyBackProposal added in v0.2.0

func NewTransferFromSwapEscrowToBuyBackProposal(title, description string, amount sdk.Coins) gov.Content

func NewTransferFromTreasuryToSwapEscrowProposal added in v0.2.0

func NewTransferFromTreasuryToSwapEscrowProposal(title, description string, amount sdk.Coins) gov.Content

func ParamKeyTable

func ParamKeyTable() params.KeyTable

func RegisterCodec

func RegisterCodec(cdc *codec.Codec)

RegisterCodec registers concrete types on codec

func SplitDisbursementReferenceKey

func SplitDisbursementReferenceKey(key []byte) string

func SplitOperatorKey

func SplitOperatorKey(key []byte) sdk.AccAddress

func ValidateGenesis

func ValidateGenesis(data GenesisState) error

ValidateGenesis validates the treasury genesis parameters

Types

type AddBuyBackLiquidityProposal

type AddBuyBackLiquidityProposal struct {
	Title       string    `json:"title" yaml:"title"`
	Description string    `json:"description" yaml:"description"`
	Amount      sdk.Coins `json:"amount" yaml:"amount"`
}

func (AddBuyBackLiquidityProposal) GetDescription

func (p AddBuyBackLiquidityProposal) GetDescription() string

func (AddBuyBackLiquidityProposal) GetTitle

func (p AddBuyBackLiquidityProposal) GetTitle() string

func (AddBuyBackLiquidityProposal) ProposalRoute

func (p AddBuyBackLiquidityProposal) ProposalRoute() string

func (AddBuyBackLiquidityProposal) ProposalType

func (p AddBuyBackLiquidityProposal) ProposalType() string

func (AddBuyBackLiquidityProposal) String

func (AddBuyBackLiquidityProposal) ValidateBasic

func (p AddBuyBackLiquidityProposal) ValidateBasic() error

type BurnDistributionProfitsProposal

type BurnDistributionProfitsProposal struct {
	Title       string    `json:"title" yaml:"title"`
	Description string    `json:"description" yaml:"description"`
	Amount      sdk.Coins `json:"amount" yaml:"amount"`
}

func (BurnDistributionProfitsProposal) GetDescription

func (p BurnDistributionProfitsProposal) GetDescription() string

func (BurnDistributionProfitsProposal) GetTitle

func (BurnDistributionProfitsProposal) ProposalRoute

func (p BurnDistributionProfitsProposal) ProposalRoute() string

func (BurnDistributionProfitsProposal) ProposalType

func (p BurnDistributionProfitsProposal) ProposalType() string

func (BurnDistributionProfitsProposal) String

func (BurnDistributionProfitsProposal) ValidateBasic

func (p BurnDistributionProfitsProposal) ValidateBasic() error

type Disbursement

type Disbursement struct {
	Operator     sdk.AccAddress `json:"operator" yaml:"operator"`
	Recipient    sdk.AccAddress `json:"recipient" yaml:"recipient"`
	Amount       sdk.Coins      `json:"amount" yaml:"amount"`
	ScheduledFor time.Time      `json:"scheduled_for" yaml:"scheduled_for"`
	Reference    string         `json:"reference" yaml:"reference"`
}

func NewDisbursement

func NewDisbursement(operator sdk.AccAddress, recipient sdk.AccAddress, amount sdk.Coins, scheduledFor time.Time, reference string) Disbursement

func (Disbursement) String

func (d Disbursement) String() string

type GenesisState

type GenesisState struct {
	Treasury  Treasury         `json:"treasury" yaml:"treasury"`
	Params    Params           `json:"params" yaml:"params"`
	Operators []sdk.AccAddress `json:"distribution_operators" yaml:"distribution_operators"`

	DisbursementQueue []Disbursement `json:"disbursement_queue" yaml:"disbursement_queue"`

	DisbursementReferences []ReferenceAmountInfo `json:"disbursement_references" yaml:"disbursement_references"`
}

GenesisState - all treasury state that must be provided at genesis

func DefaultGenesisState

func DefaultGenesisState() GenesisState

DefaultGenesisState - default GenesisState used by Cosmos Hub

func NewGenesisState

func NewGenesisState(treasury Treasury, params Params, operators []sdk.AccAddress, disbursements []Disbursement, references []ReferenceAmountInfo) GenesisState

NewGenesisState creates a new GenesisState object

type MsgAddOperator

type MsgAddOperator struct {
	Sender   sdk.AccAddress `json:"sender" yaml:"sender"`
	Operator sdk.AccAddress `json:"operator" yaml:"operator"`
}

MsgAddOperator

func NewMsgAddOperator

func NewMsgAddOperator(sender sdk.AccAddress, operator sdk.AccAddress) MsgAddOperator

func (MsgAddOperator) GetSignBytes

func (msg MsgAddOperator) GetSignBytes() []byte

func (MsgAddOperator) GetSigners

func (msg MsgAddOperator) GetSigners() []sdk.AccAddress

func (MsgAddOperator) Route

func (msg MsgAddOperator) Route() string

func (MsgAddOperator) Type

func (msg MsgAddOperator) Type() string

func (MsgAddOperator) ValidateBasic

func (msg MsgAddOperator) ValidateBasic() error

type MsgCancelDisbursement

type MsgCancelDisbursement struct {
	Manager      sdk.AccAddress `json:"manager" yaml:"manager"`
	Recipient    sdk.AccAddress `json:"recipient" yaml:"recipient"`
	ScheduledFor string         `json:"scheduled_for" yaml:"scheduled_for"` // has to be string and parsed on server because of broken amino decoding
}

MsgCancelDisbursement

func NewMsgCancelDisbursement

func NewMsgCancelDisbursement(manager sdk.AccAddress, recipient sdk.AccAddress, scheduledFor string) MsgCancelDisbursement

func (MsgCancelDisbursement) GetSignBytes

func (msg MsgCancelDisbursement) GetSignBytes() []byte

func (MsgCancelDisbursement) GetSigners

func (msg MsgCancelDisbursement) GetSigners() []sdk.AccAddress

func (MsgCancelDisbursement) Route

func (msg MsgCancelDisbursement) Route() string

func (MsgCancelDisbursement) Type

func (msg MsgCancelDisbursement) Type() string

func (MsgCancelDisbursement) ValidateBasic

func (msg MsgCancelDisbursement) ValidateBasic() error

type MsgCreateBuyOrder

type MsgCreateBuyOrder struct {
	Buyer  sdk.AccAddress `json:"buyer" yaml:"buyer"`
	Amount sdk.Coins      `json:"amount" yaml:"amount"`
}

MsgCreateBuyOrder

func NewMsgCreateBuyOrder

func NewMsgCreateBuyOrder(buyer sdk.AccAddress, amount sdk.Coins) MsgCreateBuyOrder

func (MsgCreateBuyOrder) GetSignBytes

func (msg MsgCreateBuyOrder) GetSignBytes() []byte

func (MsgCreateBuyOrder) GetSigners

func (msg MsgCreateBuyOrder) GetSigners() []sdk.AccAddress

func (MsgCreateBuyOrder) Route

func (msg MsgCreateBuyOrder) Route() string

func (MsgCreateBuyOrder) Type

func (msg MsgCreateBuyOrder) Type() string

func (MsgCreateBuyOrder) ValidateBasic

func (msg MsgCreateBuyOrder) ValidateBasic() error

type MsgCreateSellOrder

type MsgCreateSellOrder struct {
	Seller sdk.AccAddress `json:"seller" yaml:"seller"`
	Amount sdk.Coins      `json:"amount" yaml:"amount"`
}

MsgCreateSellOrder

func NewMsgCreateSellOrder

func NewMsgCreateSellOrder(seller sdk.AccAddress, amount sdk.Coins) MsgCreateSellOrder

func (MsgCreateSellOrder) GetSignBytes

func (msg MsgCreateSellOrder) GetSignBytes() []byte

func (MsgCreateSellOrder) GetSigners

func (msg MsgCreateSellOrder) GetSigners() []sdk.AccAddress

func (MsgCreateSellOrder) Route

func (msg MsgCreateSellOrder) Route() string

func (MsgCreateSellOrder) Type

func (msg MsgCreateSellOrder) Type() string

func (MsgCreateSellOrder) ValidateBasic

func (msg MsgCreateSellOrder) ValidateBasic() error

type MsgDisburse

type MsgDisburse struct {
	Operator  sdk.AccAddress `json:"operator" yaml:"operator"`
	Recipient sdk.AccAddress `json:"recipient" yaml:"recipient"`
	Amount    sdk.Coins      `json:"amount" yaml:"amount"`
	Reference string         `json:"reference" yaml:"reference"`
}

MsgDisburse

func NewMsgDisburse

func NewMsgDisburse(sender sdk.AccAddress, recipient sdk.AccAddress, amount sdk.Coins, reference string) MsgDisburse

func (MsgDisburse) GetSignBytes

func (msg MsgDisburse) GetSignBytes() []byte

func (MsgDisburse) GetSigners

func (msg MsgDisburse) GetSigners() []sdk.AccAddress

func (MsgDisburse) Route

func (msg MsgDisburse) Route() string

func (MsgDisburse) Type

func (msg MsgDisburse) Type() string

func (MsgDisburse) ValidateBasic

func (msg MsgDisburse) ValidateBasic() error

type MsgDisburseFromEscrow

type MsgDisburseFromEscrow struct {
	Operator  sdk.AccAddress `json:"operator" yaml:"operator"`
	Reference string         `json:"reference" yaml:"reference"`
	Recipient sdk.AccAddress `json:"recipient" yaml:"recipient"`
}

MsgDisburseFromEscrow

func NewMsgDisburseFromEscrow

func NewMsgDisburseFromEscrow(sender sdk.AccAddress, reference string, recipient sdk.AccAddress) MsgDisburseFromEscrow

func (MsgDisburseFromEscrow) GetSignBytes

func (msg MsgDisburseFromEscrow) GetSignBytes() []byte

func (MsgDisburseFromEscrow) GetSigners

func (msg MsgDisburseFromEscrow) GetSigners() []sdk.AccAddress

func (MsgDisburseFromEscrow) Route

func (msg MsgDisburseFromEscrow) Route() string

func (MsgDisburseFromEscrow) Type

func (msg MsgDisburseFromEscrow) Type() string

func (MsgDisburseFromEscrow) ValidateBasic

func (msg MsgDisburseFromEscrow) ValidateBasic() error

type MsgDisburseToEscrow

type MsgDisburseToEscrow struct {
	Operator  sdk.AccAddress `json:"operator" yaml:"operator"`
	Amount    sdk.Coins      `json:"amount" yaml:"amount"`
	Reference string         `json:"reference" yaml:"reference"`
}

MsgDisburseToEscrow

func NewMsgDisburseToEscrow

func NewMsgDisburseToEscrow(sender sdk.AccAddress, amount sdk.Coins, reference string) MsgDisburseToEscrow

func (MsgDisburseToEscrow) GetSignBytes

func (msg MsgDisburseToEscrow) GetSignBytes() []byte

func (MsgDisburseToEscrow) GetSigners

func (msg MsgDisburseToEscrow) GetSigners() []sdk.AccAddress

func (MsgDisburseToEscrow) Route

func (msg MsgDisburseToEscrow) Route() string

func (MsgDisburseToEscrow) Type

func (msg MsgDisburseToEscrow) Type() string

func (MsgDisburseToEscrow) ValidateBasic

func (msg MsgDisburseToEscrow) ValidateBasic() error

type MsgRemoveOperator

type MsgRemoveOperator struct {
	Sender   sdk.AccAddress `json:"sender" yaml:"sender"`
	Operator sdk.AccAddress `json:"operator" yaml:"operator"`
}

MsgRemoveOperator

func NewMsgRemoveOperator

func NewMsgRemoveOperator(sender sdk.AccAddress, operator sdk.AccAddress) MsgRemoveOperator

func (MsgRemoveOperator) GetSignBytes

func (msg MsgRemoveOperator) GetSignBytes() []byte

func (MsgRemoveOperator) GetSigners

func (msg MsgRemoveOperator) GetSigners() []sdk.AccAddress

func (MsgRemoveOperator) Route

func (msg MsgRemoveOperator) Route() string

func (MsgRemoveOperator) Type

func (msg MsgRemoveOperator) Type() string

func (MsgRemoveOperator) ValidateBasic

func (msg MsgRemoveOperator) ValidateBasic() error

type MsgRevertFromEscrow

type MsgRevertFromEscrow struct {
	Operator  sdk.AccAddress `json:"operator" yaml:"operator"`
	Amount    sdk.Coins      `json:"amount" yaml:"amount"`
	Reference string         `json:"reference" yaml:"reference"`
}

MsgRevertFromEscrow

func NewMsgRevertFromEscrow

func NewMsgRevertFromEscrow(sender sdk.AccAddress, amount sdk.Coins, reference string) MsgRevertFromEscrow

func (MsgRevertFromEscrow) GetSignBytes

func (msg MsgRevertFromEscrow) GetSignBytes() []byte

func (MsgRevertFromEscrow) GetSigners

func (msg MsgRevertFromEscrow) GetSigners() []sdk.AccAddress

func (MsgRevertFromEscrow) Route

func (msg MsgRevertFromEscrow) Route() string

func (MsgRevertFromEscrow) Type

func (msg MsgRevertFromEscrow) Type() string

func (MsgRevertFromEscrow) ValidateBasic

func (msg MsgRevertFromEscrow) ValidateBasic() error

type MsgSwap added in v0.2.0

type MsgSwap struct {
	Operator  sdk.AccAddress `json:"operator" yaml:"operator"`
	Recipient sdk.AccAddress `json:"recipient" yaml:"recipient"`
	Amount    sdk.Coins      `json:"amount" yaml:"amount"`
	Reference string         `json:"reference" yaml:"reference"`
}

MsgSwap

func NewMsgSwap added in v0.2.0

func NewMsgSwap(sender sdk.AccAddress, recipient sdk.AccAddress, amount sdk.Coins, reference string) MsgSwap

func (MsgSwap) GetSignBytes added in v0.2.0

func (msg MsgSwap) GetSignBytes() []byte

func (MsgSwap) GetSigners added in v0.2.0

func (msg MsgSwap) GetSigners() []sdk.AccAddress

func (MsgSwap) Route added in v0.2.0

func (msg MsgSwap) Route() string

func (MsgSwap) Type added in v0.2.0

func (msg MsgSwap) Type() string

func (MsgSwap) ValidateBasic added in v0.2.0

func (msg MsgSwap) ValidateBasic() error

type Params

type Params struct {
	Managers               []sdk.AccAddress `json:"managers" yaml:"managers"`
	RiskAssessmentAmount   sdk.Coins        `json:"risk_assesment_amount" yaml:"risk_assesment_amount"`
	RiskAssessmentDuration time.Duration    `json:"risk_assesment_duration" yaml:"risk_assesment_duration"`
	BuyBackPercentage      sdk.Dec          `json:"buyback_percentage" yaml:"buyback_percentage"`
}

func DefaultParams

func DefaultParams() Params

func NewParams

func NewParams(managers []sdk.AccAddress, amount sdk.Coins, riskAssessmentDuration time.Duration, buybackPercentage sdk.Dec) Params

func (*Params) ParamSetPairs

func (p *Params) ParamSetPairs() params.ParamSetPairs

func (Params) String

func (p Params) String() string

func (Params) Validate

func (p Params) Validate() error

type QueryResDisbursements

type QueryResDisbursements []Disbursement

func (QueryResDisbursements) String

func (n QueryResDisbursements) String() string

type QueryResOperators

type QueryResOperators []sdk.AccAddress

func (QueryResOperators) String

func (n QueryResOperators) String() string

type QueryResPrice

type QueryResPrice sdk.Coins

func (QueryResPrice) String

func (n QueryResPrice) String() string

type ReferenceAmountInfo

type ReferenceAmountInfo struct {
	Reference string  `json:"reference" yaml:"reference"`
	Amount    sdk.Int `json:"amount" yaml:"amount"`
}

func NewReferenceAmountInfo

func NewReferenceAmountInfo(reference string, amount sdk.Int) ReferenceAmountInfo

func (ReferenceAmountInfo) String

func (a ReferenceAmountInfo) String() string

type RemoveBuyBackLiquidityProposal

type RemoveBuyBackLiquidityProposal struct {
	Title       string    `json:"title" yaml:"title"`
	Description string    `json:"description" yaml:"description"`
	Amount      sdk.Coins `json:"amount" yaml:"amount"`
}

func (RemoveBuyBackLiquidityProposal) GetDescription

func (p RemoveBuyBackLiquidityProposal) GetDescription() string

func (RemoveBuyBackLiquidityProposal) GetTitle

func (RemoveBuyBackLiquidityProposal) ProposalRoute

func (p RemoveBuyBackLiquidityProposal) ProposalRoute() string

func (RemoveBuyBackLiquidityProposal) ProposalType

func (p RemoveBuyBackLiquidityProposal) ProposalType() string

func (RemoveBuyBackLiquidityProposal) String

func (RemoveBuyBackLiquidityProposal) ValidateBasic

func (p RemoveBuyBackLiquidityProposal) ValidateBasic() error

type TransferFromDistributionProfitsToBuyBackLiquidityProposal

type TransferFromDistributionProfitsToBuyBackLiquidityProposal struct {
	Title       string    `json:"title" yaml:"title"`
	Description string    `json:"description" yaml:"description"`
	Amount      sdk.Coins `json:"amount" yaml:"amount"`
}

func (TransferFromDistributionProfitsToBuyBackLiquidityProposal) GetDescription

func (TransferFromDistributionProfitsToBuyBackLiquidityProposal) GetTitle

func (TransferFromDistributionProfitsToBuyBackLiquidityProposal) ProposalRoute

func (TransferFromDistributionProfitsToBuyBackLiquidityProposal) ProposalType

func (TransferFromDistributionProfitsToBuyBackLiquidityProposal) String

func (TransferFromDistributionProfitsToBuyBackLiquidityProposal) ValidateBasic

type TransferFromSwapEscrowToBuyBackProposal added in v0.2.0

type TransferFromSwapEscrowToBuyBackProposal struct {
	Title       string    `json:"title" yaml:"title"`
	Description string    `json:"description" yaml:"description"`
	Amount      sdk.Coins `json:"amount" yaml:"amount"`
}

func (TransferFromSwapEscrowToBuyBackProposal) GetDescription added in v0.2.0

func (TransferFromSwapEscrowToBuyBackProposal) GetTitle added in v0.2.0

func (TransferFromSwapEscrowToBuyBackProposal) ProposalRoute added in v0.2.0

func (TransferFromSwapEscrowToBuyBackProposal) ProposalType added in v0.2.0

func (TransferFromSwapEscrowToBuyBackProposal) String added in v0.2.0

func (TransferFromSwapEscrowToBuyBackProposal) ValidateBasic added in v0.2.0

type TransferFromTreasuryToSwapEscrowProposal added in v0.2.0

type TransferFromTreasuryToSwapEscrowProposal struct {
	Title       string    `json:"title" yaml:"title"`
	Description string    `json:"description" yaml:"description"`
	Amount      sdk.Coins `json:"amount" yaml:"amount"`
}

func (TransferFromTreasuryToSwapEscrowProposal) GetDescription added in v0.2.0

func (TransferFromTreasuryToSwapEscrowProposal) GetTitle added in v0.2.0

func (TransferFromTreasuryToSwapEscrowProposal) ProposalRoute added in v0.2.0

func (TransferFromTreasuryToSwapEscrowProposal) ProposalType added in v0.2.0

func (TransferFromTreasuryToSwapEscrowProposal) String added in v0.2.0

func (TransferFromTreasuryToSwapEscrowProposal) ValidateBasic added in v0.2.0

type Treasury

type Treasury struct {
	MintGenesisSupply bool      `json:"mint_genesis_supply" yaml:"mint_genesis_supply"`
	TargetSupply      sdk.Coins `json:"target_supply" yaml:"target_supply"`
	Distributed       sdk.Coins `json:"distributed" yaml:"distributed"`
	CoinsPerStage     sdk.Coins `json:"coins_per_stage" yaml:"coins_per_stage"`
	InboundDin        sdk.Coins `json:"inbound_din" yaml:"inbound_din"`
}

func DefaultInitialTreasury

func DefaultInitialTreasury() Treasury

func InitialTreasury

func InitialTreasury(mintGenesisSupply bool, targetSupply sdk.Coins, distributed sdk.Coins, coinsPerStage sdk.Coins, inboundDin sdk.Coins) Treasury

func NewTreasury

func NewTreasury(mintGenesisSupply bool, targetSupply sdk.Coins, distributed sdk.Coins, coinsPerStage sdk.Coins, inboundDin sdk.Coins) Treasury

Jump to

Keyboard shortcuts

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