Documentation ¶
Index ¶
- type PublicDownloaderAPI
- type PublicEthereumAPI
- func (api *PublicEthereumAPI) ChainId() hexutil.Uint64
- func (s *PublicEthereumAPI) Coinbase() (common.Address, error)
- func (s *PublicEthereumAPI) Etherbase() (common.Address, error)
- func (api *PublicEthereumAPI) Hashrate() hexutil.Uint64
- func (s *PublicEthereumAPI) Mining() bool
- func (e *PublicEthereumAPI) Syncing() (interface{}, error)
- type PublicNetAPI
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PublicDownloaderAPI ¶
type PublicDownloaderAPI struct { }
PublicDownloaderAPI overwrites the `ethereum/go-ethereum/eth/downloader/api.go` and disables its features.
func NewPublicDownloaderAPI ¶
func NewPublicDownloaderAPI() *PublicDownloaderAPI
func (*PublicDownloaderAPI) SubscribeSyncStatus ¶
func (api *PublicDownloaderAPI) SubscribeSyncStatus(status chan interface{}) *downloader.SyncStatusSubscription
func (*PublicDownloaderAPI) Syncing ¶
func (api *PublicDownloaderAPI) Syncing(ctx context.Context) (*rpc.Subscription, error)
type PublicEthereumAPI ¶
type PublicEthereumAPI struct {
// contains filtered or unexported fields
}
func NewPublicEthereumAPI ¶
func NewPublicEthereumAPI(chainID *big.Int, e *eth.Ethereum, consAPI consensusAPI.API) *PublicEthereumAPI
NewPublicEthereumAPI creates a new Ethereum protocol API for full nodes.
func (*PublicEthereumAPI) ChainId ¶
func (api *PublicEthereumAPI) ChainId() hexutil.Uint64
ChainId is the EIP-155 replay-protection chain id for the current ethereum chain config.
func (*PublicEthereumAPI) Coinbase ¶ added in v1.3.1
func (s *PublicEthereumAPI) Coinbase() (common.Address, error)
Coinbase is the address that mining rewards will be send to (alias for Etherbase)
func (*PublicEthereumAPI) Etherbase ¶ added in v1.3.1
func (s *PublicEthereumAPI) Etherbase() (common.Address, error)
Etherbase is the address that mining rewards will be send to
func (*PublicEthereumAPI) Hashrate ¶
func (api *PublicEthereumAPI) Hashrate() hexutil.Uint64
Hashrate returns the POW hashrate
func (*PublicEthereumAPI) Mining ¶ added in v1.3.1
func (s *PublicEthereumAPI) Mining() bool
Mining returns an indication if this node is currently mining.
func (*PublicEthereumAPI) Syncing ¶
func (e *PublicEthereumAPI) Syncing() (interface{}, error)
Syncing returns whether or not the current node is syncing with other peers. Returns false if not, or a struct outlining the state of the sync if it is.
type PublicNetAPI ¶
type PublicNetAPI struct { NetworkVersion uint64 // contains filtered or unexported fields }
A dummy PublicNetAPI in order to overwrite the `ethereum/go-ethereum/internal/ethapi/api.go`.
func NewPublicNetAPI ¶
func NewPublicNetAPI(networkVersion uint64, consAPI consensusAPI.API) *PublicNetAPI
func (*PublicNetAPI) Listening ¶
func (n *PublicNetAPI) Listening() bool
func (*PublicNetAPI) PeerCount ¶
func (n *PublicNetAPI) PeerCount() hexutil.Uint
func (*PublicNetAPI) Version ¶
func (n *PublicNetAPI) Version() string