eth

package
v0.0.0-...-215623d Latest Latest
Warning

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

Go to latest
Published: May 20, 2021 License: GPL-3.0 Imports: 52 Imported by: 0

Documentation

Overview

Package eth implements the Ethereum protocol.

Index

Constants

View Source
const AccountRangeMaxResults = 256

AccountRangeMaxResults is the maximum number of results to be returned per call

Variables

This section is empty.

Functions

func BlockchainRuntimeConfig

func BlockchainRuntimeConfig(config *ethconfig.Config) vm.Config

func SendPendingTxsToRpcDaemon

func SendPendingTxsToRpcDaemon(txPool *core.TxPool, notifier *remotedbserver.Events)

Types

type Config

type Config = ethconfig.Config

Config contains the configuration options of the ETH protocol. Deprecated: use ethconfig.Config instead.

type Ethereum

type Ethereum struct {
	// contains filtered or unexported fields
}

Ethereum implements the Ethereum full node service.

func New

func New(stack *node.Node, config *ethconfig.Config, gitCommit string) (*Ethereum, error)

New creates a new Ethereum object (including the initialisation of the common Ethereum object)

func (*Ethereum) APIs

func (s *Ethereum) APIs() []rpc.API

func (*Ethereum) ChainKV

func (s *Ethereum) ChainKV() ethdb.RwKV

func (*Ethereum) Etherbase

func (s *Ethereum) Etherbase() (eb common.Address, err error)

func (*Ethereum) IsMining

func (s *Ethereum) IsMining() bool

func (*Ethereum) NetVersion

func (s *Ethereum) NetVersion() (uint64, error)

func (*Ethereum) Protocols

func (s *Ethereum) Protocols() []p2p.Protocol

Protocols returns all the currently configured network protocols to start.

func (*Ethereum) Start

func (s *Ethereum) Start() error

Start implements node.Lifecycle, starting all internal goroutines needed by the Ethereum protocol implementation.

func (*Ethereum) StartMining

func (s *Ethereum) StartMining(kv ethdb.RwKV, pendingBlocksCh chan *types.Block, minedBlocksCh chan *types.Block, mining *stagedsync.StagedSync, cfg params.MiningConfig, gasPrice *uint256.Int, tmpdir string, quitCh chan struct{}) error

StartMining starts the miner with the given number of CPU threads. If mining is already running, this method adjust the number of threads allowed to use and updates the minimum price required by the transaction pool.

func (*Ethereum) Stop

func (s *Ethereum) Stop() error

Stop implements node.Service, terminating all internal goroutines used by the Ethereum protocol.

func (*Ethereum) TxPool

func (s *Ethereum) TxPool() *core.TxPool

Directories

Path Synopsis
Package downloader contains the manual full chain synchronisation.
Package downloader contains the manual full chain synchronisation.
Package ethconfig contains the configuration of the ETH and LES protocols.
Package ethconfig contains the configuration of the ETH and LES protocols.
Package fetcher contains the announcement based header, blocks or transaction synchronisation.
Package fetcher contains the announcement based header, blocks or transaction synchronisation.
Package filters implements an ethereum filtering system for block, transactions and log events.
Package filters implements an ethereum filtering system for block, transactions and log events.
protocols
eth
Package tracers is a collection of JavaScript transaction tracers.
Package tracers is a collection of JavaScript transaction tracers.
internal/tracers
Package tracers contains the actual JavaScript tracer assets.
Package tracers contains the actual JavaScript tracer assets.

Jump to

Keyboard shortcuts

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