keeper

package
v4.2.1-alpha.1 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: MIT Imports: 15 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) AllBids

func (Keeper) AllForSale

func (Keeper) AllInits

func (Keeper) AllNames

func (Keeper) Bid

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

CheckExistence quickly checks if there are any domains registered

func (Keeper) ForSale

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) GetPrimaryName added in v4.1.0

func (k Keeper) GetPrimaryName(
	ctx sdk.Context,
	owner string,
) (val types.Names, found bool)

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) ListOwnedNames

func (Keeper) Logger

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

func (Keeper) Name

func (Keeper) Params

func (Keeper) PrimaryName added in v4.1.0

func (Keeper) RegisterRNSName added in v4.1.0

func (k Keeper) RegisterRNSName(ctx sdk.Context, sender string, nm string, data string, years int64, primary bool) 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) Resolve

func (k Keeper) Resolve(ctx sdk.Context, name string) (sdk.AccAddress, error)

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) SetPrimaryName added in v4.1.0

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

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

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