keeper

package
v0.12.1 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMsgServerImpl

func NewMsgServerImpl(keeper Keeper) types.MsgServer

NewMsgServerImpl returns an implementation of the token MsgServer interface for the provided Keeper.

Types

type Keeper

type Keeper struct {
	// contains filtered or unexported fields
}

func NewKeeper

func NewKeeper(
	cdc codec.Codec,
	storeKey sdk.StoreKey,
	accountKeeper types.AccountKeeper,
	bankKeeper types.BankKeeper,
	nftKeeper types.NftKeeper,
	streampayKeeper types.StreamPayKeeper,
	distributionKeeper types.DistributionKeeper,
	ps paramtypes.Subspace,
) Keeper

func (Keeper) Campaign

Campaign returns details of the campaign

func (Keeper) Campaigns

func (Keeper) CancelCampaign

func (k Keeper) CancelCampaign(ctx sdk.Context, campaignId uint64, creator sdk.AccAddress) error

CancelCampaign ...

func (Keeper) Claim

func (k Keeper) Claim(ctx sdk.Context, campaign types.Campaign, claimer sdk.AccAddress, claim types.Claim) error

Claim ...

func (Keeper) Claims

func (Keeper) CreateCampaign

func (k Keeper) CreateCampaign(
	ctx sdk.Context,
	creator sdk.AccAddress,
	campaign types.Campaign,
	creationFee sdk.Coin,
) error

CreateCampaign ...

func (Keeper) DepositCampaign

func (k Keeper) DepositCampaign(ctx sdk.Context, campaignId uint64, depositor sdk.AccAddress, amount sdk.Coin) error

func (Keeper) FinalizeAndEndCampaigns

func (k Keeper) FinalizeAndEndCampaigns(ctx sdk.Context) error

FinalizeAndEndCampaigns finalizes and ends and all campaigns that are reached end time

func (Keeper) GetAllCampaigns

func (k Keeper) GetAllCampaigns(ctx sdk.Context) (list []types.Campaign)

GetAllCampaigns returns all campaigns

func (Keeper) GetCampaign

func (k Keeper) GetCampaign(ctx sdk.Context, id uint64) (val types.Campaign, found bool)

GetCampaign returns a campaign by its id

func (Keeper) GetCampaignCreationFee

func (k Keeper) GetCampaignCreationFee(ctx sdk.Context) (creationFee sdk.Coin)

GetCampaignCreationFee returns the creation fee required to create a campaign.

func (Keeper) GetCampaignsByCreator

func (k Keeper) GetCampaignsByCreator(ctx sdk.Context, creator sdk.AccAddress) (campaigns []types.Campaign)

GetCampaignsByCreator returns all campaigns created by specific address

func (Keeper) GetClaims

func (k Keeper) GetClaims(ctx sdk.Context, campaignId uint64) (claims []types.Claim)

func (Keeper) GetMaxCampaignDuration

func (k Keeper) GetMaxCampaignDuration(ctx sdk.Context) (duration time.Duration)

GetMaxCampaignDuration returns the maximum duration allowed to create a campaign.

func (Keeper) GetModuleAccountAddress

func (k Keeper) GetModuleAccountAddress(ctx sdk.Context) sdk.AccAddress

func (Keeper) GetNextCampaignNumber

func (k Keeper) GetNextCampaignNumber(ctx sdk.Context) uint64

GetNextCampaignNumber get the next campaign number

func (Keeper) GetParams

func (k Keeper) GetParams(ctx sdk.Context) (params types.Params)

GetParams gets the parameters for the itc module.

func (Keeper) HasCampaign

func (k Keeper) HasCampaign(ctx sdk.Context, id uint64) bool

func (Keeper) HasClaim

func (k Keeper) HasClaim(ctx sdk.Context, id uint64, nftId string) bool

func (Keeper) Logger

func (k Keeper) Logger(ctx sdk.Context) log.Logger

func (Keeper) Params

Params returns params of the itc module.

func (Keeper) RemoveCampaign

func (k Keeper) RemoveCampaign(ctx sdk.Context, id uint64)

RemoveCampaign removes a campaign from the store

func (Keeper) RemoveClaims

func (k Keeper) RemoveClaims(ctx sdk.Context, campaignId uint64)

func (Keeper) SetCampaign

func (k Keeper) SetCampaign(ctx sdk.Context, campaign types.Campaign)

SetCampaign set a specific campaign in the store

func (Keeper) SetCampaignWithCreator

func (k Keeper) SetCampaignWithCreator(ctx sdk.Context, creator sdk.AccAddress, id uint64)

func (Keeper) SetClaim

func (k Keeper) SetClaim(ctx sdk.Context, claim types.Claim)

func (Keeper) SetNextCampaignNumber

func (k Keeper) SetNextCampaignNumber(ctx sdk.Context, number uint64)

SetNextCampaignNumber set the next campaign number

func (Keeper) SetParams

func (k Keeper) SetParams(ctx sdk.Context, params types.Params)

SetParams sets the parameters for the itc module.

func (Keeper) UnsetCampaignWithCreator

func (k Keeper) UnsetCampaignWithCreator(ctx sdk.Context, creator sdk.AccAddress, id uint64)

Jump to

Keyboard shortcuts

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