Documentation ¶
Index ¶
- Variables
- func NewOutportDataProvider(arg ArgOutportDataProvider) (*outportDataProvider, error)
- func WrapTxsMap(txs map[string]data.TransactionHandler) map[string]data.TransactionHandlerWithGasUsedAndFee
- type AlteredAccountsProviderHandler
- type ArgOutportDataProvider
- type ArgPrepareOutportSaveBlockData
- type EconomicsDataHandler
- type ExecutionOrderHandler
- type GasConsumedProvider
- type TransactionsFeeHandler
Constants ¶
This section is empty.
Variables ¶
var ErrNilEnableEpochsHandler = errors.New("nil enable epochs handler")
ErrNilEnableEpochsHandler signals that a nil enable epochs handler has been provided
var ErrNilGasConsumedProvider = errors.New("nil gas consumed provider")
ErrNilGasConsumedProvider signals that a nil gas consumed provider has been provided
var ErrNilHasher = errors.New("nil hasher provided")
ErrNilHasher signals that a nil hasher has been provided
var ErrNilNodesCoordinator = errors.New("validator group selector is nil")
ErrNilNodesCoordinator is raised when a valid validator group selector is expected but nil used
var ErrNilStorer = errors.New("nil storer")
ErrNilStorer is raised when a nil storer has been provided
var ErrNilTransactionCoordinator = errors.New("transaction coordinator is nil")
ErrNilTransactionCoordinator signals that transaction coordinator is nil
Functions ¶
func NewOutportDataProvider ¶
func NewOutportDataProvider(arg ArgOutportDataProvider) (*outportDataProvider, error)
NewOutportDataProvider will create a new instance of outportDataProvider
func WrapTxsMap ¶
func WrapTxsMap(txs map[string]data.TransactionHandler) map[string]data.TransactionHandlerWithGasUsedAndFee
Types ¶
type AlteredAccountsProviderHandler ¶
type AlteredAccountsProviderHandler interface { ExtractAlteredAccountsFromPool(txPool *outport.Pool, options shared.AlteredAccountsOptions) (map[string]*outport.AlteredAccount, error) IsInterfaceNil() bool }
AlteredAccountsProviderHandler defines the functionality needed for provisioning of altered accounts when indexing data
type ArgOutportDataProvider ¶
type ArgOutportDataProvider struct { IsImportDBMode bool ShardCoordinator sharding.Coordinator AlteredAccountsProvider AlteredAccountsProviderHandler TransactionsFeeProcessor TransactionsFeeHandler TxCoordinator process.TransactionCoordinator NodesCoordinator nodesCoordinator.NodesCoordinator GasConsumedProvider GasConsumedProvider EconomicsData EconomicsDataHandler ExecutionOrderHandler ExecutionOrderHandler }
ArgOutportDataProvider holds the arguments needed for creating a new instance of outportDataProvider
type ArgPrepareOutportSaveBlockData ¶
type ArgPrepareOutportSaveBlockData struct { HeaderHash []byte Header data.HeaderHandler Body data.BodyHandler PreviousHeader data.HeaderHandler RewardsTxs map[string]data.TransactionHandler NotarizedHeadersHashes []string }
ArgPrepareOutportSaveBlockData holds the arguments needed for prepare outport save block data
type EconomicsDataHandler ¶
type EconomicsDataHandler interface { ComputeGasUsedAndFeeBasedOnRefundValue(tx data.TransactionWithFeeHandler, refundValue *big.Int) (uint64, *big.Int) ComputeTxFeeBasedOnGasUsed(tx data.TransactionWithFeeHandler, gasUsed uint64) *big.Int ComputeGasLimit(tx data.TransactionWithFeeHandler) uint64 IsInterfaceNil() bool MaxGasLimitPerBlock(shardID uint32) uint64 }
EconomicsDataHandler defines the functionality needed for economics data
type ExecutionOrderHandler ¶
type ExecutionOrderHandler interface { PutExecutionOrderInTransactionPool( pool *outport.Pool, header data.HeaderHandler, body data.BodyHandler, prevHeader data.HeaderHandler, ) ([]string, []string, error) }
ExecutionOrderHandler defines the interface for the execution order handler