Documentation ¶
Index ¶
- Constants
- func MakeFundCommunityPoolMsg(fundCommunityPoolMsg types.FundCommunityPoolMsg, depositorAddr sdk.AccAddress) (disttypes.MsgFundCommunityPool, error)
- func MakeProposalCommunityPoolSpendMsg(communityPoolSpendMsg types.CommunityPoolSpendMsg, from sdk.AccAddress, ...) (govtypes.MsgSubmitProposal, error)
- func MakeQueryCommunityPoolMsg() (disttypes.QueryCommunityPoolRequest, error)
- func MakeQueryDistCommissionMsg(queryDistCommissionMsg types.QueryDistCommissionMsg) (disttypes.QueryValidatorCommissionRequest, error)
- func MakeQueryDistRewardsMsg(queryDistRewardsMsg types.QueryDistRewardsMsg) (disttypes.QueryDelegationRewardsRequest, error)
- func MakeQueryDistSlashesMsg(queryDistSlashesMsg types.QueryDistSlashesMsg) (disttypes.QueryValidatorSlashesRequest, error)
- func MakeQueryDistTotalRewardsMsg(queryDistRewardsMsg types.QueryDistRewardsMsg) (disttypes.QueryDelegationTotalRewardsRequest, error)
- func MakeQueryDistributionParamsMsg() (disttypes.QueryParamsRequest, error)
- func MakeSetWithdrawAddrMsg(setWithdrawAddrMsg types.SetWithdrawAddrMsg, delAddr sdk.AccAddress) (disttypes.MsgSetWithdrawAddress, error)
- func MakeValidatorOutstandingRewardsMsg(validatorOutstandingRewardsMsg types.ValidatorOutstandingRewardsMsg) (disttypes.QueryValidatorOutstandingRewardsRequest, error)
- func MakeWithdrawAllRewardsMsg(delAddr sdk.AccAddress, grpcConn grpc.ClientConn, ctx context.Context) ([]sdk.Msg, error)
- func MakeWithdrawRewardsMsg(withdrawRewardsMsg types.WithdrawRewardsMsg, delAddr sdk.AccAddress) ([]sdk.Msg, error)
- func NewCoreModule() core.CoreModule
- func QueryDistribution(i core.QueryClient) (string, error)
- type DistributionExternal
- func (e DistributionExternal) CommunityPool() provider.XplaClient
- func (e DistributionExternal) CommunityPoolSpend(communityPoolSpendMsg types.CommunityPoolSpendMsg) provider.XplaClient
- func (e DistributionExternal) DistCommission(queryDistCommissionMsg types.QueryDistCommissionMsg) provider.XplaClient
- func (e DistributionExternal) DistRewards(queryDistRewardsMsg types.QueryDistRewardsMsg) provider.XplaClient
- func (e DistributionExternal) DistSlashes(queryDistSlashesMsg types.QueryDistSlashesMsg) provider.XplaClient
- func (e DistributionExternal) DistributionParams() provider.XplaClient
- func (e DistributionExternal) FundCommunityPool(fundCommunityPoolMsg types.FundCommunityPoolMsg) provider.XplaClient
- func (e DistributionExternal) SetWithdrawAddr(setWithdrawAddrMsg types.SetWithdrawAddrMsg) provider.XplaClient
- func (e DistributionExternal) ValidatorOutstandingRewards(validatorOutstandingRewardsMsg types.ValidatorOutstandingRewardsMsg) provider.XplaClient
- func (e DistributionExternal) WithdrawAllRewards() provider.XplaClient
- func (e DistributionExternal) WithdrawRewards(withdrawRewardsMsg types.WithdrawRewardsMsg) provider.XplaClient
Constants ¶
const ( DistributionModule = "distribution" DistributionFundCommunityPoolMsgType = "fund-community-pool" DistributionProposalCommunityPoolSpendMsgType = "proposal-community-pool-spend" DistributionWithdrawRewardsMsgType = "withdraw-rewards" DistributionWithdrawAllRewardsMsgType = "withdraw-all-rewards" DistributionSetWithdrawAddrMsgType = "set-withdraw-addr" DistributionQueryDistributionParamsMsgType = "query-distribution-params" DistributionValidatorOutstandingRewardsMsgType = "validator-outstanding-rewards" DistributionQueryDistCommissionMsgType = "dist-query-commission" DistributionQuerySlashesMsgType = "dist-slashes" DistributionQueryRewardsMsgType = "dist-rewards" DistributionQueryTotalRewardsMsgType = "dist-total-rewards" DistributionQueryCommunityPoolMsgType = "query-community-pool" )
Variables ¶
This section is empty.
Functions ¶
func MakeFundCommunityPoolMsg ¶
func MakeFundCommunityPoolMsg(fundCommunityPoolMsg types.FundCommunityPoolMsg, depositorAddr sdk.AccAddress) (disttypes.MsgFundCommunityPool, error)
(Tx) make msg - fund community pool
func MakeProposalCommunityPoolSpendMsg ¶
func MakeProposalCommunityPoolSpendMsg(communityPoolSpendMsg types.CommunityPoolSpendMsg, from sdk.AccAddress, encodingConfig params.EncodingConfig) (govtypes.MsgSubmitProposal, error)
(Tx) make msg - proposal community pool
func MakeQueryCommunityPoolMsg ¶
func MakeQueryCommunityPoolMsg() (disttypes.QueryCommunityPoolRequest, error)
(Query) make msg - community pool
func MakeQueryDistCommissionMsg ¶
func MakeQueryDistCommissionMsg(queryDistCommissionMsg types.QueryDistCommissionMsg) (disttypes.QueryValidatorCommissionRequest, error)
(Query) make msg - commission
func MakeQueryDistRewardsMsg ¶
func MakeQueryDistRewardsMsg(queryDistRewardsMsg types.QueryDistRewardsMsg) (disttypes.QueryDelegationRewardsRequest, error)
(Query) make msg - distribution rewards
func MakeQueryDistSlashesMsg ¶
func MakeQueryDistSlashesMsg(queryDistSlashesMsg types.QueryDistSlashesMsg) (disttypes.QueryValidatorSlashesRequest, error)
(Query) make msg - distribution slashes
func MakeQueryDistTotalRewardsMsg ¶
func MakeQueryDistTotalRewardsMsg(queryDistRewardsMsg types.QueryDistRewardsMsg) (disttypes.QueryDelegationTotalRewardsRequest, error)
(Query) make msg - distribution all rewards
func MakeQueryDistributionParamsMsg ¶
func MakeQueryDistributionParamsMsg() (disttypes.QueryParamsRequest, error)
(Query) make msg - distribution params
func MakeSetWithdrawAddrMsg ¶
func MakeSetWithdrawAddrMsg(setWithdrawAddrMsg types.SetWithdrawAddrMsg, delAddr sdk.AccAddress) (disttypes.MsgSetWithdrawAddress, error)
(Tx) make msg - withdraw address
func MakeValidatorOutstandingRewardsMsg ¶
func MakeValidatorOutstandingRewardsMsg(validatorOutstandingRewardsMsg types.ValidatorOutstandingRewardsMsg) (disttypes.QueryValidatorOutstandingRewardsRequest, error)
(Query) make msg - validator outstanding rewards
func MakeWithdrawAllRewardsMsg ¶
func MakeWithdrawAllRewardsMsg(delAddr sdk.AccAddress, grpcConn grpc.ClientConn, ctx context.Context) ([]sdk.Msg, error)
(Tx) make msg - withdraw all rewards
func MakeWithdrawRewardsMsg ¶
func MakeWithdrawRewardsMsg(withdrawRewardsMsg types.WithdrawRewardsMsg, delAddr sdk.AccAddress) ([]sdk.Msg, error)
(Tx) make msg - withdraw rewards
func NewCoreModule ¶ added in v0.1.2
func NewCoreModule() core.CoreModule
func QueryDistribution ¶
func QueryDistribution(i core.QueryClient) (string, error)
Query client for distribution module.
Types ¶
type DistributionExternal ¶ added in v0.1.2
type DistributionExternal struct {
Xplac provider.XplaClient
}
func NewDistributionExternal ¶ added in v0.1.2
func NewDistributionExternal(xplac provider.XplaClient) (e DistributionExternal)
func (DistributionExternal) CommunityPool ¶ added in v0.1.2
func (e DistributionExternal) CommunityPool() provider.XplaClient
Query the amount of coins in the community pool.
func (DistributionExternal) CommunityPoolSpend ¶ added in v0.1.2
func (e DistributionExternal) CommunityPoolSpend(communityPoolSpendMsg types.CommunityPoolSpendMsg) provider.XplaClient
Submit a community pool spend proposal.
func (DistributionExternal) DistCommission ¶ added in v0.1.2
func (e DistributionExternal) DistCommission(queryDistCommissionMsg types.QueryDistCommissionMsg) provider.XplaClient
Query distribution validator commission.
func (DistributionExternal) DistRewards ¶ added in v0.1.2
func (e DistributionExternal) DistRewards(queryDistRewardsMsg types.QueryDistRewardsMsg) provider.XplaClient
Query all ditribution delegator rewards or rewards from a particular validator.
func (DistributionExternal) DistSlashes ¶ added in v0.1.2
func (e DistributionExternal) DistSlashes(queryDistSlashesMsg types.QueryDistSlashesMsg) provider.XplaClient
Query distribution validator slashes.
func (DistributionExternal) DistributionParams ¶ added in v0.1.2
func (e DistributionExternal) DistributionParams() provider.XplaClient
Query distribution parameters.
func (DistributionExternal) FundCommunityPool ¶ added in v0.1.2
func (e DistributionExternal) FundCommunityPool(fundCommunityPoolMsg types.FundCommunityPoolMsg) provider.XplaClient
Funds the community pool with the specified amount.
func (DistributionExternal) SetWithdrawAddr ¶ added in v0.1.2
func (e DistributionExternal) SetWithdrawAddr(setWithdrawAddrMsg types.SetWithdrawAddrMsg) provider.XplaClient
Change the default withdraw address for rewards associated with an address.
func (DistributionExternal) ValidatorOutstandingRewards ¶ added in v0.1.2
func (e DistributionExternal) ValidatorOutstandingRewards(validatorOutstandingRewardsMsg types.ValidatorOutstandingRewardsMsg) provider.XplaClient
Query distribution outstanding (un-withdrawn) rewards for a validator and all their delegations.
func (DistributionExternal) WithdrawAllRewards ¶ added in v0.1.2
func (e DistributionExternal) WithdrawAllRewards() provider.XplaClient
Withdraw all delegations rewards for a delegator.
func (DistributionExternal) WithdrawRewards ¶ added in v0.1.2
func (e DistributionExternal) WithdrawRewards(withdrawRewardsMsg types.WithdrawRewardsMsg) provider.XplaClient
Withdraw rewards from a given delegation address, and optionally withdraw validator commission if the delegation address given is a validator operator.