query

package
v0.0.0-...-8cda47c Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ABCIInfoRPC

func ABCIInfoRPC(q *Query) (*coretypes.ResultABCIInfo, error)

ABCIInfoRPC returns information about the ABCI application

func ABCIQueryRPC

func ABCIQueryRPC(q *Query, path string, data string, prove bool) (*coretypes.ResultABCIQuery, error)

ABCIQueryRPC returns data from a particular path in the ABCI application

func BlockByHashRPC

func BlockByHashRPC(q *Query, hash string) (*coretypes.ResultBlock, error)

BlockByHashRPC returns information about a block by hash

func BlockRPC

func BlockRPC(q *Query) (*coretypes.ResultBlock, error)

BlockRPC returns information about a block

func BlockResultsRPC

func BlockResultsRPC(q *Query) (*coretypes.ResultBlockResults, error)

BlockResultsRPC returns information about a block by hash

func StatusRPC

func StatusRPC(q *Query) (*coretypes.ResultStatus, error)

StatusRPC returns information about a node status

func TxsRPC

func TxsRPC(q *Query, events []string) (*coretypes.ResultTxSearch, error)

QueryTxs returns an results of a TxSearch for a given tag

Types

type Query

type Query struct {
	Client  *client.ChainClient
	Options *QueryOptions
}

func (*Query) ABCIInfo

func (q *Query) ABCIInfo() (*coretypes.ResultABCIInfo, error)

ABCIInfo returns general information about the ABCI application

func (*Query) ABCIQuery

func (q *Query) ABCIQuery(path string, data string, prove bool) (*coretypes.ResultABCIQuery, error)

ABCIQuery returns data from a particular path in the ABCI application

func (*Query) Bank_Balance

func (q *Query) Bank_Balance(address string, denom string) (*bankTypes.QueryBalanceResponse, error)

Balances returns the balance of specific denom for a single account.

func (*Query) Bank_Balances

func (q *Query) Bank_Balances(address string) (*bankTypes.QueryAllBalancesResponse, error)

Balances returns the balance of all coins for a single account.

func (*Query) Bank_DenomMetadata

func (q *Query) Bank_DenomMetadata(denom string) (*bankTypes.QueryDenomMetadataResponse, error)

DenomMetadata returns the metadata for given denoms

func (*Query) Bank_DenomsMetadata

func (q *Query) Bank_DenomsMetadata() (*bankTypes.QueryDenomsMetadataResponse, error)

DenomsMetadata returns the metadata for all denoms

func (*Query) Bank_Params

func (q *Query) Bank_Params() (*bankTypes.QueryParamsResponse, error)

Return params for bank module.

func (*Query) Bank_SupplyOf

func (q *Query) Bank_SupplyOf(denom string) (*bankTypes.QuerySupplyOfResponse, error)

SupplyOf returns the supply of given coin

func (*Query) Bank_TotalSupply

func (q *Query) Bank_TotalSupply() (*bankTypes.QueryTotalSupplyResponse, error)

TotalSupply returns the supply of all coins

func (*Query) Block

func (q *Query) Block() (*coretypes.ResultBlock, error)

Block returns information about a block

func (*Query) BlockByHash

func (q *Query) BlockByHash(hash string) (*coretypes.ResultBlock, error)

BlockByHash returns information about a block by hash

func (*Query) BlockResults

func (q *Query) BlockResults() (*coretypes.ResultBlockResults, error)

BlockResults returns information about a block by hash

func (*Query) GetQueryContext

func (q *Query) GetQueryContext() (context.Context, context.CancelFunc)

GetQueryContext returns a context that includes the height and uses the timeout from the config

func (*Query) Status

func (q *Query) Status() (*coretypes.ResultStatus, error)

Status returns information about a node status

type QueryOptions

type QueryOptions struct {
	Pagination *query.PageRequest
	Height     int64
}

func DefaultOptions

func DefaultOptions() *QueryOptions

Jump to

Keyboard shortcuts

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