Documentation ¶
Index ¶
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- type Keeper
- func (k Keeper) Campaign(goCtx context.Context, req *types.QueryCampaignRequest) (*types.QueryCampaignResponse, error)
- func (k Keeper) Campaigns(goCtx context.Context, req *types.QueryCampaignsRequest) (*types.QueryCampaignsResponse, error)
- func (k Keeper) DistributeRewards(ctx sdk.Context, receiver types.Receiver) (uint64, error)
- func (k Keeper) GetAllCampaign(ctx sdk.Context) (list []types.Campaign)
- func (k Keeper) GetAllRewards(ctx sdk.Context) (list []types.Reward)
- func (k Keeper) GetAllRewardsByCampaign(ctx sdk.Context) (list []types.RewardByCampaign)
- func (k Keeper) GetAllRewardsByReceiverAndCategory(ctx sdk.Context) (list []types.RewardByCategory)
- func (k Keeper) GetCampaign(ctx sdk.Context, uid string) (val types.Campaign, found bool)
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetReward(ctx sdk.Context, uid string) (val types.Reward, found bool)
- func (k Keeper) GetRewardsByAddressAndCategory(ctx sdk.Context, address string, category types.RewardCategory) (list []types.RewardByCategory, err error)
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) Params(goCtx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) RemoveCampaign(ctx sdk.Context, uid string)
- func (k Keeper) RemoveReward(ctx sdk.Context, uid string)
- func (k Keeper) Reward(goCtx context.Context, req *types.QueryRewardRequest) (*types.QueryRewardResponse, error)
- func (k Keeper) Rewards(goCtx context.Context, req *types.QueryRewardsRequest) (*types.QueryRewardsResponse, error)
- func (k Keeper) RewardsByAddress(goCtx context.Context, req *types.QueryRewardsByAddressRequest) (*types.QueryRewardsByAddressResponse, error)
- func (k Keeper) RewardsByAddressAndCategory(goCtx context.Context, req *types.QueryRewardsByAddressAndCategoryRequest) (*types.QueryRewardsByAddressAndCategoryResponse, error)
- func (k Keeper) RewardsByCampaign(goCtx context.Context, req *types.QueryRewardsByCampaignRequest) (*types.QueryRewardsByCampaignResponse, error)
- func (k Keeper) SetCampaign(ctx sdk.Context, campaign types.Campaign)
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k Keeper) SetReward(ctx sdk.Context, reward types.Reward)
- func (k Keeper) SetRewardByCampaign(ctx sdk.Context, rewByCampaign types.RewardByCampaign)
- func (k Keeper) SetRewardByReceiver(ctx sdk.Context, rByCategory types.RewardByCategory)
- func (k Keeper) UpdateCampaignPool(ctx sdk.Context, campaign types.Campaign, receiver types.Receiver)
- type SdkExpectedKeepers
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 {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, storeKey, memKey storetypes.StoreKey, ps paramtypes.Subspace, betKeeper types.BetKeeper, ovmKeeper types.OVMKeeper, subaccountKeeper types.SubAccountKeeper, expectedKeepers SdkExpectedKeepers, ) *Keeper
func (Keeper) Campaign ¶
func (k Keeper) Campaign(goCtx context.Context, req *types.QueryCampaignRequest) (*types.QueryCampaignResponse, error)
func (Keeper) Campaigns ¶
func (k Keeper) Campaigns(goCtx context.Context, req *types.QueryCampaignsRequest) (*types.QueryCampaignsResponse, error)
func (Keeper) DistributeRewards ¶
DistributeRewards distributes the rewards according to the input distribution list.
func (Keeper) GetAllCampaign ¶
GetAllCampaign returns all campaign
func (Keeper) GetAllRewards ¶
GetAllRewards returns all reward
func (Keeper) GetAllRewardsByCampaign ¶
func (k Keeper) GetAllRewardsByCampaign(ctx sdk.Context) (list []types.RewardByCampaign)
GetAllRewardsByCampaign returns all rewards by campaign
func (Keeper) GetAllRewardsByReceiverAndCategory ¶
func (k Keeper) GetAllRewardsByReceiverAndCategory(ctx sdk.Context) (list []types.RewardByCategory)
GetAllRewardsByReceiverAndCategory returns all rewards by receiver and category
func (Keeper) GetCampaign ¶
GetCampaign returns a campaign from its index
func (Keeper) GetRewardsByAddressAndCategory ¶
func (k Keeper) GetRewardsByAddressAndCategory( ctx sdk.Context, address string, category types.RewardCategory, ) (list []types.RewardByCategory, err error)
GetRewardsByAddressAndCategory returns all rewards by address and category.
func (Keeper) Params ¶
func (k Keeper) Params(goCtx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) RemoveCampaign ¶
RemoveCampaign removes a campaign from the store
func (Keeper) RemoveReward ¶
RemoveReward removes a reward from the store
func (Keeper) Reward ¶
func (k Keeper) Reward(goCtx context.Context, req *types.QueryRewardRequest) (*types.QueryRewardResponse, error)
func (Keeper) Rewards ¶
func (k Keeper) Rewards(goCtx context.Context, req *types.QueryRewardsRequest) (*types.QueryRewardsResponse, error)
func (Keeper) RewardsByAddress ¶
func (k Keeper) RewardsByAddress(goCtx context.Context, req *types.QueryRewardsByAddressRequest) (*types.QueryRewardsByAddressResponse, error)
func (Keeper) RewardsByAddressAndCategory ¶
func (k Keeper) RewardsByAddressAndCategory(goCtx context.Context, req *types.QueryRewardsByAddressAndCategoryRequest) (*types.QueryRewardsByAddressAndCategoryResponse, error)
func (Keeper) RewardsByCampaign ¶
func (k Keeper) RewardsByCampaign(goCtx context.Context, req *types.QueryRewardsByCampaignRequest) (*types.QueryRewardsByCampaignResponse, error)
func (Keeper) SetCampaign ¶
SetCampaign set a specific campaign in the store from its index
func (Keeper) SetRewardByCampaign ¶
func (k Keeper) SetRewardByCampaign(ctx sdk.Context, rewByCampaign types.RewardByCampaign)
func (Keeper) SetRewardByReceiver ¶
func (k Keeper) SetRewardByReceiver(ctx sdk.Context, rByCategory types.RewardByCategory)
type SdkExpectedKeepers ¶
type SdkExpectedKeepers struct { AuthzKeeper types.AuthzKeeper BankKeeper types.BankKeeper AccountKeeper types.AccountKeeper }
SdkExpectedKeepers contains expected keepers parameter needed by NewKeeper