keeper

package
v2.1.1-0...-d24ec66 Latest Latest
Warning

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

Go to latest
Published: Jul 11, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetCost

func GetCost(tld string) int64

func GetCostOfName

func GetCostOfName(name string, tld string) (int64, error)

func GetNameAndTLD

func GetNameAndTLD(full string) (string, string, error)

func GetSubdomain

func GetSubdomain(name string) (string, string, bool)

func GetTLD

func GetTLD(name string) (string, error)

func NewMsgServerImpl

func NewMsgServerImpl(keeper Keeper) types.MsgServer

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

func RemoveTLD

func RemoveTLD(name string, tld string) (string, error)

Types

type Keeper

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

func NewKeeper

func NewKeeper(
	cdc codec.BinaryCodec,
	storeKey sdk.StoreKey,
	ps paramtypes.Subspace,

	bankKeeper types.BankKeeper,
) *Keeper

func (Keeper) AcceptOneBid

func (k Keeper) AcceptOneBid(ctx sdk.Context, sender string, name string, bidder string) error

func (Keeper) AddBid

func (k Keeper) AddBid(ctx sdk.Context, sender string, name string, bid string) error

func (Keeper) Bids

func (Keeper) BuyName

func (k Keeper) BuyName(ctx sdk.Context, sender string, nm string) error

func (Keeper) CancelOneBid

func (k Keeper) CancelOneBid(ctx sdk.Context, sender string, name string) error

func (Keeper) CheckExistence

func (k Keeper) CheckExistence(ctx sdk.Context) bool

quickly checks if there are any domains registered

func (Keeper) GetAllBids

func (k Keeper) GetAllBids(ctx sdk.Context) (list []types.Bids)

GetAllBids returns all bids

func (Keeper) GetAllForsale

func (k Keeper) GetAllForsale(ctx sdk.Context) (list []types.Forsale)

GetAllForsale returns all forsale

func (Keeper) GetAllInit

func (k Keeper) GetAllInit(ctx sdk.Context) (list []types.Init)

GetAllInit returns all init

func (Keeper) GetAllNames

func (k Keeper) GetAllNames(ctx sdk.Context) (list []types.Names)

GetAllNames returns all names

func (Keeper) GetAllWhois

func (k Keeper) GetAllWhois(ctx sdk.Context) (list []types.Whois)

GetAllWhois returns all whois

func (Keeper) GetBids

func (k Keeper) GetBids(
	ctx sdk.Context,
	index string,
) (val types.Bids, found bool)

GetBids returns a bids from its index

func (Keeper) GetForsale

func (k Keeper) GetForsale(
	ctx sdk.Context,
	name string,
) (val types.Forsale, found bool)

GetForsale returns a forsale from its index

func (Keeper) GetInit

func (k Keeper) GetInit(
	ctx sdk.Context,
	address string,
) (val types.Init, found bool)

GetInit returns a init from its index

func (Keeper) GetNames

func (k Keeper) GetNames(
	ctx sdk.Context,
	name string,
	tld string,
) (val types.Names, found bool)

GetNames returns a names from its index

func (Keeper) GetParams

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

GetParams get all parameters as types.Params

func (Keeper) GetWhois

func (k Keeper) GetWhois(
	ctx sdk.Context,
	index string,
) (val types.Whois, found bool)

GetWhois returns a whois from its index

func (Keeper) Init

func (Keeper) Logger

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

func (Keeper) Names

func (Keeper) Params

func (Keeper) RegisterName

func (k Keeper) RegisterName(ctx sdk.Context, sender string, nm string, data string, years string) error

func (Keeper) RemoveBids

func (k Keeper) RemoveBids(
	ctx sdk.Context,
	index string,
)

RemoveBids removes a bids from the store

func (Keeper) RemoveForsale

func (k Keeper) RemoveForsale(
	ctx sdk.Context,
	name string,
)

RemoveForsale removes a forsale from the store

func (Keeper) RemoveInit

func (k Keeper) RemoveInit(
	ctx sdk.Context,
	address string,
)

RemoveInit removes a init from the store

func (Keeper) RemoveNames

func (k Keeper) RemoveNames(
	ctx sdk.Context,
	name string,
	tld string,
)

RemoveNames removes a names from the store

func (Keeper) RemoveWhois

func (k Keeper) RemoveWhois(
	ctx sdk.Context,
	index string,
)

RemoveWhois removes a whois from the store

func (Keeper) SetBids

func (k Keeper) SetBids(ctx sdk.Context, bids types.Bids)

SetBids set a specific bids in the store from its index

func (Keeper) SetForsale

func (k Keeper) SetForsale(ctx sdk.Context, forsale types.Forsale)

SetForsale set a specific forsale in the store from its index

func (Keeper) SetInit

func (k Keeper) SetInit(ctx sdk.Context, init types.Init)

SetInit set a specific init in the store from its index

func (Keeper) SetNames

func (k Keeper) SetNames(ctx sdk.Context, names types.Names)

SetNames set a specific names in the store from its index

func (Keeper) SetParams

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

SetParams set the params

func (Keeper) SetWhois

func (k Keeper) SetWhois(ctx sdk.Context, whois types.Whois)

SetWhois set a specific whois in the store from its index

func (Keeper) TransferName

func (k Keeper) TransferName(ctx sdk.Context, creator string, receiever string, name string) error

func (Keeper) UpdateName

func (k Keeper) UpdateName(ctx sdk.Context, sender string, nm string, data string) error

func (Keeper) Whois

type Migrator

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

Migrator is a struct for handling in-place store migrations.

func NewMigrator

func NewMigrator(keeper Keeper) Migrator

NewMigrator returns a new Migrator

func (Migrator) Migrate1to2

func (m Migrator) Migrate1to2(ctx sdk.Context) error

Migrate1to2 migrates from version 1 to 2.

Jump to

Keyboard shortcuts

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