diff options
author | Sonic <sonic@dexon.org> | 2018-11-09 14:49:23 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-04-09 21:32:53 +0800 |
commit | a31ae3fde50d3402e838483c985dbe50d753b48c (patch) | |
tree | bd58f09231948a732bb23db753ca83605f85bffe /dex/backend.go | |
parent | 089257a3da86184c66f666ff8e119e1ca7850357 (diff) | |
download | dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.tar dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.tar.gz dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.tar.bz2 dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.tar.lz dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.tar.xz dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.tar.zst dexon-a31ae3fde50d3402e838483c985dbe50d753b48c.zip |
dex: use dex/downloader in dex
To compatible with ethereum code base, make Downloader a
interface in internal/ethapi
Diffstat (limited to 'dex/backend.go')
-rw-r--r-- | dex/backend.go | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/dex/backend.go b/dex/backend.go index 36b28345c..8fe9e9ea3 100644 --- a/dex/backend.go +++ b/dex/backend.go @@ -33,7 +33,7 @@ import ( "github.com/dexon-foundation/dexon/core/rawdb" "github.com/dexon-foundation/dexon/core/vm" "github.com/dexon-foundation/dexon/dex/blockdb" - "github.com/dexon-foundation/dexon/eth/downloader" + "github.com/dexon-foundation/dexon/dex/downloader" "github.com/dexon-foundation/dexon/eth/filters" "github.com/dexon-foundation/dexon/eth/gasprice" "github.com/dexon-foundation/dexon/ethdb" @@ -266,12 +266,12 @@ func CreateDB(ctx *node.ServiceContext, config *Config, name string) (ethdb.Data return db, nil } -func (d *Dexon) AccountManager() *accounts.Manager { return d.accountManager } -func (d *Dexon) BlockChain() *core.BlockChain { return d.blockchain } -func (d *Dexon) TxPool() *core.TxPool { return d.txPool } -func (d *Dexon) DexVersion() int { return int(d.protocolManager.SubProtocols[0].Version) } -func (d *Dexon) EventMux() *event.TypeMux { return d.eventMux } -func (d *Dexon) Engine() consensus.Engine { return d.engine } -func (d *Dexon) ChainDb() ethdb.Database { return d.chainDb } -func (d *Dexon) Downloader() *downloader.Downloader { return d.protocolManager.downloader } -func (d *Dexon) NetVersion() uint64 { return d.networkID } +func (d *Dexon) AccountManager() *accounts.Manager { return d.accountManager } +func (d *Dexon) BlockChain() *core.BlockChain { return d.blockchain } +func (d *Dexon) TxPool() *core.TxPool { return d.txPool } +func (d *Dexon) DexVersion() int { return int(d.protocolManager.SubProtocols[0].Version) } +func (d *Dexon) EventMux() *event.TypeMux { return d.eventMux } +func (d *Dexon) Engine() consensus.Engine { return d.engine } +func (d *Dexon) ChainDb() ethdb.Database { return d.chainDb } +func (d *Dexon) Downloader() ethapi.Downloader { return d.protocolManager.downloader } +func (d *Dexon) NetVersion() uint64 { return d.networkID } |