types

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EventType = "instance"

	AttributeKeyHash    = "hash"
	AttributeKeyService = "service"

	AttributeActionCreated = "created"
)

module event types and attributes

View Source
const (
	// ModuleName is the name of the module
	ModuleName = "instance"

	// StoreKey to be used when creating the KVStore
	StoreKey = ModuleName

	// RouterKey to be used for routing msgs
	RouterKey = ModuleName

	// QuerierRoute to be used for routing
	QuerierRoute = ModuleName
)
View Source
const (
	QueryGet  = "get"
	QueryList = "list"
)

Query endpoints supported by the instance querier

Variables

View Source
var ModuleCdc *codec.Codec

ModuleCdc defines the module codec

Functions

func RegisterCodec

func RegisterCodec(cdc *codec.Codec)

RegisterCodec registers concrete types on codec

func ValidateGenesis

func ValidateGenesis(data GenesisState) error

ValidateGenesis validates the instance genesis parameters

Types

type GenesisState

type GenesisState struct {
	Instances []*instance.Instance `json:"instances" yaml:"instances" validate:"dive"`
}

GenesisState - all instance state that must be provided at genesis

func DefaultGenesisState

func DefaultGenesisState() GenesisState

DefaultGenesisState is the default GenesisState

func NewGenesisState

func NewGenesisState(instances []*instance.Instance) GenesisState

NewGenesisState creates a new GenesisState object

type ServiceKeeper added in v0.23.0

type ServiceKeeper interface {
	Get(ctx sdk.Context, hash hash.Hash) (*servicepb.Service, error)
}

ServiceKeeper module interface.

Jump to

Keyboard shortcuts

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