keeper

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 13 Imported by: 46

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 circuit MsgServer interface for the provided Keeper.

func NewQueryServer

func NewQueryServer(keeper Keeper) types.QueryServer

NewQueryServer returns an implementation of the circuit QueryServer interface for the provided Keeper.

Types

type Keeper

type Keeper struct {
	Schema collections.Schema
	// Permissions contains the permissions for each account
	Permissions collections.Map[[]byte, types.Permissions]
	// DisableList contains the message URLs that are disabled
	DisableList collections.KeySet[string]
	// contains filtered or unexported fields
}

Keeper defines the circuit module's keeper.

func NewKeeper

func NewKeeper(cdc codec.BinaryCodec, storeService store.KVStoreService, authority string, addressCodec address.Codec) Keeper

NewKeeper constructs a new Circuit Keeper instance

func (*Keeper) ExportGenesis

func (k *Keeper) ExportGenesis(ctx context.Context) (data *types.GenesisState)

func (*Keeper) GetAuthority

func (k *Keeper) GetAuthority() []byte

func (*Keeper) InitGenesis

func (k *Keeper) InitGenesis(ctx context.Context, genState *types.GenesisState)

InitGenesis initializes the circuit module's state from a given genesis state.

func (*Keeper) IsAllowed

func (k *Keeper) IsAllowed(ctx context.Context, msgURL string) (bool, error)

IsAllowed returns true when msg URL is not found in the DisableList for given context, else false.

type QueryServer

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

func (QueryServer) Account

Account returns account permissions.

func (QueryServer) Accounts

Account returns account permissions.

func (QueryServer) DisabledList

DisabledList returns a list of disabled message urls

Jump to

Keyboard shortcuts

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