query

package
v0.1.14-dev3 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2025 License: MIT Imports: 27 Imported by: 0

Documentation

Overview

Package query provides interfaces used to query the state of the blockchain. These interfaces abstract the underlying request/response types and provide a single method to query for a specific piece of information from the chain.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrQueryAccountNotFound            = sdkerrors.Register(codespace, 1, "account not found")
	ErrQueryUnableToDeserializeAccount = sdkerrors.Register(codespace, 2, "unable to deserialize account")
	ErrQueryRetrieveSession            = sdkerrors.Register(codespace, 3, "error while trying to retrieve a session")
	ErrQueryPubKeyNotFound             = sdkerrors.Register(codespace, 4, "account pub key not found")
	ErrQuerySessionParams              = sdkerrors.Register(codespace, 5, "unable to query session params")
	ErrQueryRetrieveService            = sdkerrors.Register(codespace, 6, "error while trying to retrieve a service")
	ErrQueryBalanceNotFound            = sdkerrors.Register(codespace, 7, "balance not found")
)

Functions

func NewAccountQuerier

func NewAccountQuerier(deps depinject.Config) (client.AccountQueryClient, error)

NewAccountQuerier returns a new instance of a client.AccountQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - clientCtx

func NewApplicationQuerier

func NewApplicationQuerier(deps depinject.Config) (client.ApplicationQueryClient, error)

NewApplicationQuerier returns a new instance of a client.ApplicationQueryClient by injecting the dependencies provided by the depinject.Config

Required dependencies: - clientCtx

func NewBankQuerier added in v0.0.10

func NewBankQuerier(deps depinject.Config) (client.BankQueryClient, error)

NewBankQuerier returns a new instance of a client.BankQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - clientCtx - polylog.Logger - cache.KeyValueCache[Balance]

func NewProofQuerier added in v0.0.3

func NewProofQuerier(deps depinject.Config) (client.ProofQueryClient, error)

NewProofQuerier returns a new instance of a client.ProofQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - grpc.ClientConn - polylog.Logger - client.ParamsCache[prooftypes.Params] - cache.KeyValueCache[prooftypes.Claim]

func NewServiceQuerier added in v0.0.8

func NewServiceQuerier(deps depinject.Config) (client.ServiceQueryClient, error)

NewServiceQuerier returns a new instance of a client.ServiceQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - clientCtx (grpc.ClientConn) - polylog.Logger - cache.KeyValueCache[sharedtypes.Service] - cache.KeyValueCache[servicetypes.RelayMiningDifficulty]

func NewSessionQuerier

func NewSessionQuerier(deps depinject.Config) (client.SessionQueryClient, error)

NewSessionQuerier returns a new instance of a client.SessionQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - clientCtx (grpc.ClientConn)

func NewSharedQuerier added in v0.0.3

func NewSharedQuerier(deps depinject.Config) (client.SharedQueryClient, error)

NewSharedQuerier returns a new instance of a client.SharedQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - clientCtx (grpc.ClientConn) - client.BlockQueryClient

func NewSupplierQuerier

func NewSupplierQuerier(deps depinject.Config) (client.SupplierQueryClient, error)

NewSupplierQuerier returns a new instance of a client.SupplierQueryClient by injecting the dependencies provided by the depinject.Config.

Required dependencies: - grpc.ClientConn - polylog.Logger - cache.KeyValueCache[sharedtypes.Supplier]

Types

type Balance added in v0.0.14

type Balance *cosmostypes.Coin

Balance represents a pointer to a Cosmos SDK Coin used for bank balance queries. It is defined as a distinct type (not an alias) to: - Ensure clear dependency injection - Differentiate from other coin caches in the system - Maintain separation of concerns between coin-related data in the caching layer

type BlockHash added in v0.0.14

type BlockHash []byte

BlockHash represents a byte slice used for bank balance query caches. It is defined as a distinct type (not an alias) to: - Ensure clear dependency injection - Differentiate from other byte slice caches - Maintain separation of concerns between byte slice data in caching layer

type Context added in v0.0.14

type Context cosmosclient.Context

Context represents a CosmosSDK client Context used for query operations. It is defined as a distinct type (not an alias) to: - Ensure clear dependency injection - Differentiate from transaction-related contexts - Maintain separation of concerns between query and transaction operations

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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