keeper

package
v0.6.28 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2023 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ServiceRecordKeyPrefix is the prefix to retrieve all ServiceRecord
	ServiceRecordKeyPrefix = "ServiceRecord/value/"
)

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.

func ServiceRecordKey added in v0.6.28

func ServiceRecordKey(
	index string,
) []byte

ServiceRecordKey returns the store key to retrieve a ServiceRecord from the index fields

Types

type Keeper

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

func NewKeeper

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

	groupKeeper types.GroupKeeper,
	identityKeeper types.IdentityKeeper,
	vaultKeeper types.VaultKeeper,
) *Keeper

func (Keeper) AuthenticateUser added in v0.6.27

The `AuthenticateUser` function is a method of the `Keeper` struct and is used to authenticate a user. It takes a context and an `AuthenticateUserRequest` as input and returns an `AuthenticateUserResponse` and an error. However, in the given code, the function is not implemented and returns an error message indicating that it is not implemented.

func (Keeper) BroadcastTx added in v0.6.28

func (k Keeper) BroadcastTx(ctx sdk.Context, bz []byte) error

BroadcastTx is a method of the `Keeper` struct and is used to broadcast a transaction to the blockchain. It takes a context, a `vaulttypes.Account` and a `sdk.Msg` as input and returns nothing. The function first unwraps the context and then signs the message using the `SignCosmosTx`

func (Keeper) GetAllServiceRecord

func (k Keeper) GetAllServiceRecord(ctx sdk.Context) (list []types.ServiceRecord)

GetAllServiceRecord returns all serviceRecord

func (Keeper) GetParams

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

GetParams get all parameters as types.Params

func (Keeper) GetServiceRecord

func (k Keeper) GetServiceRecord(ctx sdk.Context, origin string) (val types.ServiceRecord, found bool)

GetServiceRecord returns a serviceRecord from its id

func (Keeper) GetServiceRecordCount added in v0.6.28

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

GetServiceRecordCount get the total number of serviceRecord

func (Keeper) Logger

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

func (Keeper) Params

func (Keeper) RegisterUser added in v0.6.27

This function is a method of the `Keeper` struct and is used to register a new user identity. It takes a context and a `RegisterUserRequest` as input and returns a `RegisterUserResponse` and an error. The function first retrieves the service record associated with the request origin and checks if the desired alias is available. It then retrieves the claimable wallet associated with the request UCW ID and verifies the creation challenge using the service's `VerifyCreationChallenge` method. If the challenge is verified, the function assigns an identity to the user using the `AssignIdentity` method of the identity keeper and returns the assigned identity and its ID in the response. If any error occurs during the process, the function returns an error.

func (Keeper) RemoveServiceRecord

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

RemoveServiceRecord removes a serviceRecord from the store

func (Keeper) ServiceAssertion added in v0.6.26

func (Keeper) ServiceAttestation added in v0.6.27

ServiceAttestion returns the attestion options for a given service record and desired Identity alias

func (Keeper) SetParams

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

SetParams set the params

func (Keeper) SetServiceRecord

func (k Keeper) SetServiceRecord(ctx sdk.Context, serviceRecord types.ServiceRecord)

SetServiceRecord set a specific serviceRecord in the store

func (Keeper) SetServiceRecordCount added in v0.6.28

func (k Keeper) SetServiceRecordCount(ctx sdk.Context, count uint64)

SetServiceRecordCount set the total number of serviceRecord

Jump to

Keyboard shortcuts

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