keeper

package
v0.0.0-...-1129d62 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2026 License: AGPL-3.0 Imports: 15 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 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 storetypes.StoreKey,
	authorities []string,
	statsKeeper types.StatsKeeper,
	indexerEventManager indexer_manager.IndexerEventManager,
) *Keeper

func (Keeper) AffiliateInfo

func (Keeper) GetAffiliateOverrides

func (k Keeper) GetAffiliateOverrides(ctx sdk.Context) (types.AffiliateOverrides, error)

func (Keeper) GetAffiliateOverridesMap

func (k Keeper) GetAffiliateOverridesMap(ctx sdk.Context) (map[string]bool, error)

func (Keeper) GetAffiliateParameters

func (k Keeper) GetAffiliateParameters(ctx sdk.Context) (types.AffiliateParameters, error)

func (Keeper) GetAffiliateWhitelist

func (k Keeper) GetAffiliateWhitelist(ctx sdk.Context) (types.AffiliateWhitelist, error)

DO NOT USE: This will be deprecated soon.

func (Keeper) GetAffiliateWhitelistMap deprecated

func (k Keeper) GetAffiliateWhitelistMap(ctx sdk.Context) (map[string]uint32, error)

Deprecated: This is deprecated in favor of AffiliateOverride.

func (Keeper) GetAllAffiliateTiers

func (k Keeper) GetAllAffiliateTiers(ctx sdk.Context) (types.AffiliateTiers, error)

GetAllAffiliateTiers returns all affiliate tiers.

func (Keeper) GetAllAffilliateOverrides

func (k Keeper) GetAllAffilliateOverrides(ctx sdk.Context) (types.AffiliateOverrides, error)

func (Keeper) GetIndexerEventManager

func (k Keeper) GetIndexerEventManager() indexer_manager.IndexerEventManager

func (Keeper) GetReferredBy

func (k Keeper) GetReferredBy(ctx sdk.Context, referee string) (string, bool)

GetReferredBy returns the affiliate address for a referee address.

func (Keeper) GetTakerFeeShare

func (k Keeper) GetTakerFeeShare(
	ctx sdk.Context,
	address string,
	affiliateOverrides map[string]bool,
) (
	affiliateAddress string,
	feeSharePpm uint32,
	exists bool,
	err error,
)

GetTakerFeeShare returns the taker fee share for an address based on the affiliate tiers. If the address is in the whitelist, the fee share ppm is overridden.

func (Keeper) GetTierForAffiliate

func (k Keeper) GetTierForAffiliate(
	ctx sdk.Context,
	affiliateAddr string,
	affiliateOverrides map[string]bool,
) (
	tierLevel uint32,
	feeSharePpm uint32,
	err error)

GetTierForAffiliate returns the tier an affiliate address is qualified for. Assumes that the affiliate tiers are sorted by level in ascending order.

func (Keeper) HasAuthority

func (k Keeper) HasAuthority(authority string) bool

func (Keeper) InitializeForGenesis

func (k Keeper) InitializeForGenesis(ctx sdk.Context)

func (Keeper) Logger

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

func (Keeper) ReferredBy

func (Keeper) RegisterAffiliate

func (k Keeper) RegisterAffiliate(
	ctx sdk.Context,
	referee string,
	affiliateAddr string,
) error

RegisterAffiliate registers an affiliate address for a referee address.

func (Keeper) SetAffiliateOverrides

func (k Keeper) SetAffiliateOverrides(ctx sdk.Context, overrides types.AffiliateOverrides) error

func (Keeper) SetAffiliateWhitelist deprecated

func (k Keeper) SetAffiliateWhitelist(ctx sdk.Context, whitelist types.AffiliateWhitelist) error

Deprecated: This is deprecated in favor of AffiliateOverride.

func (*Keeper) SetFeetiersKeeper

func (k *Keeper) SetFeetiersKeeper(feetiersKeeper types.FeetiersKeeper)

func (Keeper) UpdateAffiliateParameters

func (k Keeper) UpdateAffiliateParameters(
	ctx sdk.Context,
	msg *types.MsgUpdateAffiliateParameters,
) error

func (Keeper) UpdateAffiliateTiers

func (k Keeper) UpdateAffiliateTiers(ctx sdk.Context, affiliateTiers types.AffiliateTiers) error

UpdateAffiliateTiers updates the affiliate tiers. Used primarily through governance.

Jump to

Keyboard shortcuts

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