keeper

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetBytesFromUint64

func GetBytesFromUint64(id uint64) []byte

GetBytesFromUint64 returns the byte representation of the ID

func GetUInt64FromBytes

func GetUInt64FromBytes(bz []byte) uint64

GetUInt64FromBytes returns ID in uint64 format from a byte array

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,
	memKey storetypes.StoreKey,
	bankKeeper types.BankKeeper,
) *Keeper

func (Keeper) CheckCommonError

func (k Keeper) CheckCommonError(tokenId string, symbol string, name string, supply uint64) error

func (Keeper) GetAllToken

func (k Keeper) GetAllToken(ctx sdk.Context) (list []types.Token)

GetAllToken returns all token

func (Keeper) GetToken

func (k Keeper) GetToken(ctx sdk.Context, id string) (val types.Token, found bool)

GetToken returns a token from its id

func (Keeper) Logger

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

func (Keeper) RemoveToken

func (k Keeper) RemoveToken(ctx sdk.Context, id string)

RemoveToken removes a token from the store

func (Keeper) SetToken

func (k Keeper) SetToken(ctx sdk.Context, token types.Token)

SetToken set a specific token in the store

func (Keeper) SetTokenToAccount

func (k Keeper) SetTokenToAccount(ctx sdk.Context, token types.Token)

Jump to

Keyboard shortcuts

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