indexer

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2022 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccountTokenData

type AccountTokenData struct {
	Identifier string        `json:"identifier"`
	Balance    string        `json:"balance"`
	Nonce      uint64        `json:"nonce"`
	Properties string        `json:"properties"`
	MetaData   *dct.MetaData `json:"metadata"`
}

AccountTokenData holds the data needed for indexing a token of an altered account

type AlteredAccount

type AlteredAccount struct {
	Address string              `json:"address"`
	Balance string              `json:"balance,omitempty"`
	Nonce   uint64              `json:"nonce"`
	Tokens  []*AccountTokenData `json:"tokens"`
}

AlteredAccount holds the data needed of an altered account in a block

type ArgsSaveBlockData

type ArgsSaveBlockData struct {
	HeaderHash             []byte
	Body                   data.BodyHandler
	Header                 data.HeaderHandler
	SignersIndexes         []uint64
	NotarizedHeadersHashes []string
	HeaderGasConsumption   HeaderGasConsumption
	TransactionsPool       *Pool
	AlteredAccounts        map[string]*AlteredAccount
}

ArgsSaveBlockData will contains all information that are needed to save block data

type HeaderGasConsumption

type HeaderGasConsumption struct {
	GasProvided    uint64
	GasRefunded    uint64
	GasPenalized   uint64
	MaxGasPerBlock uint64
}

HeaderGasConsumption holds the data needed to save the gas consumption of a header

type Pool

type Pool struct {
	Txs      map[string]data.TransactionHandler
	Scrs     map[string]data.TransactionHandler
	Rewards  map[string]data.TransactionHandler
	Invalid  map[string]data.TransactionHandler
	Receipts map[string]data.TransactionHandler
	Logs     []*data.LogData
}

Pool will holds all types of transaction

type RoundInfo

type RoundInfo struct {
	Index            uint64
	SignersIndexes   []uint64
	BlockWasProposed bool
	ShardId          uint32
	Epoch            uint32
	Timestamp        time.Duration
}

RoundInfo is a structure containing block signers and shard id

type ValidatorRatingInfo

type ValidatorRatingInfo struct {
	PublicKey string
	Rating    float32
}

ValidatorRatingInfo is a structure containing validator rating information

Jump to

Keyboard shortcuts

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