"centralised" mining to backend. Closes #323

This commit is contained in:
obscuren
2015-02-17 12:24:51 +01:00
parent 164de5e22b
commit 8135752a32
11 changed files with 47 additions and 96 deletions

View File

@ -25,7 +25,7 @@ type FilterOptions struct {
// Filtering interface
type Filter struct {
eth EthManager
eth Backend
earliest int64
latest int64
skip int
@ -40,7 +40,7 @@ type Filter struct {
// Create a new filter which uses a bloom filter on blocks to figure out whether a particular block
// is interesting or not.
func NewFilter(eth EthManager) *Filter {
func NewFilter(eth Backend) *Filter {
return &Filter{eth: eth}
}

View File

@ -7,12 +7,11 @@ import (
"github.com/ethereum/go-ethereum/p2p"
)
type EthManager interface {
type Backend interface {
BlockProcessor() *BlockProcessor
ChainManager() *ChainManager
TxPool() *TxPool
PeerCount() int
IsMining() bool
IsListening() bool
Peers() []*p2p.Peer
KeyManager() *crypto.KeyManager