diff options
author | Sonic <sonic@dexon.org> | 2018-11-09 14:49:23 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-03-12 12:19:09 +0800 |
commit | e508bf0a8074e803cbcdaa162fd3289de2afda94 (patch) | |
tree | ac10c3cced1f817d12bd2e4c0c9e50d8a1d7e3bd /dex/backend.go | |
parent | 202b8a467827118e1243b98dbd8111c3d806211e (diff) | |
download | dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.tar dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.tar.gz dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.tar.bz2 dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.tar.lz dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.tar.xz dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.tar.zst dexon-e508bf0a8074e803cbcdaa162fd3289de2afda94.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 } |