Documentation ¶
Index ¶
- Constants
- func BalancesToAccounts(balances []banktypes.Balance) []sdk.AccAddress
- func ExtendedValidatorsRequestToValidatorsRequest(request *telemetrytypes.QueryExtendedValidatorsRequest) *stakingtypes.QueryValidatorsRequest
- func NewQuerier(keeper Keeper, cdc *codec.LegacyAmino) sdk.Querier
- func ValidatorsResponseToExtendedValidatorsResponse(request *stakingtypes.QueryValidatorsResponse) *telemetrytypes.QueryExtendedValidatorsResponse
- func ValidatorsToAccounts(validators []stakingtypes.Validator) ([]sdk.AccAddress, error)
- type Keeper
- func (k Keeper) AvgBlockSize(_ context.Context, request *telemetrytypes.QueryAvgBlockSizeRequest) (*telemetrytypes.QueryAvgBlockSizeResponse, error)
- func (k Keeper) AvgBlockTime(_ context.Context, request *telemetrytypes.QueryAvgBlockTimeRequest) (*telemetrytypes.QueryAvgBlockTimeResponse, error)
- func (k Keeper) AvgTxFee(c context.Context, request *telemetrytypes.QueryAvgTxFeeRequest) (*telemetrytypes.QueryAvgTxFeeResponse, error)
- func (k Keeper) ExtendedValidators(c context.Context, request *telemetrytypes.QueryExtendedValidatorsRequest) (*telemetrytypes.QueryExtendedValidatorsResponse, error)
- func (k Keeper) GetAccountTxsCount(accounts ...sdk.AccAddress) (map[string]int64, error)
- func (k Keeper) GetAvgBlockSizePerDay(startDate, endDate *time.Time) ([]telemetrytypes.AverageBlockSizePerDay, error)
- func (k Keeper) GetAvgBlockTimePerDay(startDate, endDate *time.Time) ([]telemetrytypes.AverageBlockTimePerDay, error)
- func (k Keeper) GetAvgTxFeePerDay(startDate, endDate *time.Time) ([]telemetrytypes.AverageTxFeePerDay, error)
- func (k Keeper) GetBalances(ctx sdk.Context, addrs ...sdk.AccAddress) []banktypes.Balance
- func (k Keeper) GetBlockValidators(blockHeight int64) ([]tendermint.Validator, error)
- func (k Keeper) GetBlocksByDates(startDate, endDate *time.Time) (map[time.Time][]*tendermint.Block, error)
- func (k Keeper) GetBlocksByValidator(ctx sdk.Context, valAddr sdk.ValAddress) ([]telemetrytypes.ValidatorBlock, error)
- func (k Keeper) GetPaginatedBalances(ctx sdk.Context, denom string, desc bool, pagination *query.PageRequest) ([]banktypes.Balance, uint64)
- func (k Keeper) GetTopValidatorsByBlocks(ctx sdk.Context, startDate, endDate *time.Time, desc bool, ...) ([]telemetrytypes.ValidatorBlockStats, uint64, error)
- func (k Keeper) GetTxVolumePerDay(startDate, endDate *time.Time) ([]telemetrytypes.TxVolumePerDay, error)
- func (k Keeper) GetTxs(page, maxTxsPerPage int) (*coretypes.ResultTxSearch, error)
- func (k Keeper) GetValidatorBlocks(ctx sdk.Context, valAddr sdk.ValAddress, desc bool, ...) ([]telemetrytypes.ValidatorBlock, uint64, error)
- func (k Keeper) TopBalances(c context.Context, request *telemetrytypes.QueryTopBalancesRequest) (*telemetrytypes.QueryTopBalancesResponse, error)
- func (k Keeper) TopValidators(c context.Context, request *telemetrytypes.QueryTopValidatorsRequest) (*telemetrytypes.QueryTopValidatorsResponse, error)
- func (k Keeper) TxVolume(c context.Context, request *telemetrytypes.QueryTxVolumeRequest) (*telemetrytypes.QueryTxVolumeResponse, error)
- func (k Keeper) ValidatorBlocks(c context.Context, request *telemetrytypes.QueryValidatorBlocksRequest) (*telemetrytypes.QueryValidatorBlocksResponse, error)
- func (k Keeper) ValidatorByConsAddr(c context.Context, request *telemetrytypes.QueryValidatorByConsAddrRequest) (*telemetrytypes.QueryValidatorByConsAddrResponse, error)
Constants ¶
View Source
const ( MaxCountPerPage = 100 AllBlocksQuery = "block.height > 1" OrderByAsc = "asc" )
View Source
const (
QueryAllTxs = "tx.height >= 1"
)
Variables ¶
This section is empty.
Functions ¶
func BalancesToAccounts ¶
func BalancesToAccounts(balances []banktypes.Balance) []sdk.AccAddress
func ExtendedValidatorsRequestToValidatorsRequest ¶
func ExtendedValidatorsRequestToValidatorsRequest(request *telemetrytypes.QueryExtendedValidatorsRequest) *stakingtypes.QueryValidatorsRequest
func NewQuerier ¶
func NewQuerier(keeper Keeper, cdc *codec.LegacyAmino) sdk.Querier
func ValidatorsResponseToExtendedValidatorsResponse ¶
func ValidatorsResponseToExtendedValidatorsResponse(request *stakingtypes.QueryValidatorsResponse) *telemetrytypes.QueryExtendedValidatorsResponse
func ValidatorsToAccounts ¶
func ValidatorsToAccounts(validators []stakingtypes.Validator) ([]sdk.AccAddress, error)
Types ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, txCfg client.TxConfig, bk bankkeeper.ViewKeeper, sk stakingkeeper.Keeper, dk distrkeeper.Keeper, ) Keeper
func (Keeper) AvgBlockSize ¶
func (k Keeper) AvgBlockSize( _ context.Context, request *telemetrytypes.QueryAvgBlockSizeRequest, ) (*telemetrytypes.QueryAvgBlockSizeResponse, error)
func (Keeper) AvgBlockTime ¶
func (k Keeper) AvgBlockTime( _ context.Context, request *telemetrytypes.QueryAvgBlockTimeRequest, ) (*telemetrytypes.QueryAvgBlockTimeResponse, error)
func (Keeper) AvgTxFee ¶
func (k Keeper) AvgTxFee( c context.Context, request *telemetrytypes.QueryAvgTxFeeRequest, ) (*telemetrytypes.QueryAvgTxFeeResponse, error)
func (Keeper) ExtendedValidators ¶
func (k Keeper) ExtendedValidators( c context.Context, request *telemetrytypes.QueryExtendedValidatorsRequest, ) (*telemetrytypes.QueryExtendedValidatorsResponse, error)
func (Keeper) GetAccountTxsCount ¶
GetAccountTxsCount TODO: very bad method, it is better not to use it, or rewrite it more optimized
func (Keeper) GetAvgBlockSizePerDay ¶
func (k Keeper) GetAvgBlockSizePerDay(startDate, endDate *time.Time) ([]telemetrytypes.AverageBlockSizePerDay, error)
func (Keeper) GetAvgBlockTimePerDay ¶
func (k Keeper) GetAvgBlockTimePerDay(startDate, endDate *time.Time) ([]telemetrytypes.AverageBlockTimePerDay, error)
func (Keeper) GetAvgTxFeePerDay ¶
func (k Keeper) GetAvgTxFeePerDay(startDate, endDate *time.Time) ([]telemetrytypes.AverageTxFeePerDay, error)
func (Keeper) GetBalances ¶
func (Keeper) GetBlockValidators ¶
func (k Keeper) GetBlockValidators(blockHeight int64) ([]tendermint.Validator, error)
func (Keeper) GetBlocksByDates ¶
func (Keeper) GetBlocksByValidator ¶
func (k Keeper) GetBlocksByValidator(ctx sdk.Context, valAddr sdk.ValAddress) ([]telemetrytypes.ValidatorBlock, error)
func (Keeper) GetPaginatedBalances ¶
func (Keeper) GetTopValidatorsByBlocks ¶
func (k Keeper) GetTopValidatorsByBlocks( ctx sdk.Context, startDate, endDate *time.Time, desc bool, pagination *query.PageRequest, ) ([]telemetrytypes.ValidatorBlockStats, uint64, error)
func (Keeper) GetTxVolumePerDay ¶
func (k Keeper) GetTxVolumePerDay(startDate, endDate *time.Time) ([]telemetrytypes.TxVolumePerDay, error)
func (Keeper) GetTxs ¶
func (k Keeper) GetTxs(page, maxTxsPerPage int) (*coretypes.ResultTxSearch, error)
func (Keeper) GetValidatorBlocks ¶
func (k Keeper) GetValidatorBlocks( ctx sdk.Context, valAddr sdk.ValAddress, desc bool, pagination *query.PageRequest, ) ([]telemetrytypes.ValidatorBlock, uint64, error)
func (Keeper) TopBalances ¶
func (k Keeper) TopBalances( c context.Context, request *telemetrytypes.QueryTopBalancesRequest, ) (*telemetrytypes.QueryTopBalancesResponse, error)
func (Keeper) TopValidators ¶
func (k Keeper) TopValidators( c context.Context, request *telemetrytypes.QueryTopValidatorsRequest, ) (*telemetrytypes.QueryTopValidatorsResponse, error)
func (Keeper) TxVolume ¶
func (k Keeper) TxVolume( c context.Context, request *telemetrytypes.QueryTxVolumeRequest, ) (*telemetrytypes.QueryTxVolumeResponse, error)
func (Keeper) ValidatorBlocks ¶
func (k Keeper) ValidatorBlocks( c context.Context, request *telemetrytypes.QueryValidatorBlocksRequest, ) (*telemetrytypes.QueryValidatorBlocksResponse, error)
func (Keeper) ValidatorByConsAddr ¶
func (k Keeper) ValidatorByConsAddr(c context.Context, request *telemetrytypes.QueryValidatorByConsAddrRequest) (*telemetrytypes.QueryValidatorByConsAddrResponse, error)
Click to show internal directories.
Click to hide internal directories.