registry

package
v0.2201.0 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2022 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Overview

Package registry implements the registry application.

Index

Constants

View Source
const (
	// AppID is the unique application identifier.
	AppID uint8 = 0x01

	// AppName is the ABCI application name.
	AppName string = "200_registry"
)

Variables

View Source
var (
	// EventType is the ABCI event type for registry events.
	EventType = api.EventTypeForApp(AppName)

	// QueryApp is a query for filtering events processed by
	// the registry application.
	QueryApp = api.QueryForApp(AppName)
)

Functions

func New

func New() api.Application

New constructs a new registry application instance.

Types

type Query

type Query interface {
	Entity(context.Context, signature.PublicKey) (*entity.Entity, error)
	Entities(context.Context) ([]*entity.Entity, error)
	Node(context.Context, signature.PublicKey) (*node.Node, error)
	NodeByConsensusAddress(context.Context, []byte) (*node.Node, error)
	NodeStatus(context.Context, signature.PublicKey) (*registry.NodeStatus, error)
	Nodes(context.Context) ([]*node.Node, error)
	Runtime(context.Context, common.Namespace) (*registry.Runtime, error)
	Runtimes(ctx context.Context, includeSuspended bool) ([]*registry.Runtime, error)
	Genesis(context.Context) (*registry.Genesis, error)
}

Query is the registry query interface.

type QueryFactory

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

QueryFactory is the registry query factory.

func NewQueryFactory

func NewQueryFactory(state abciAPI.ApplicationQueryState) *QueryFactory

NewQueryFactory returns a new QueryFactory backed by the given state instance.

func (*QueryFactory) QueryAt

func (sf *QueryFactory) QueryAt(ctx context.Context, height int64) (Query, error)

QueryAt returns the registry query interface for a specific height.

Directories

Path Synopsis
Package api defines the registry application API for other applications.
Package api defines the registry application API for other applications.

Jump to

Keyboard shortcuts

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