aboutsummaryrefslogtreecommitdiffstats
path: root/ethpipe/config.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-10-31 21:30:08 +0800
committerobscuren <geffobscura@gmail.com>2014-10-31 21:30:08 +0800
commit0ed1a8b50a9b9726cd57a2731d0405f6949c6188 (patch)
tree9f877ecdc89b784cd2820db8ca3f1de6e9c4d3e9 /ethpipe/config.go
parent8826e9694c3a8d4f480f0a021d8c02f7f61612c6 (diff)
downloaddexon-0ed1a8b50a9b9726cd57a2731d0405f6949c6188.tar.gz
dexon-0ed1a8b50a9b9726cd57a2731d0405f6949c6188.tar.zst
dexon-0ed1a8b50a9b9726cd57a2731d0405f6949c6188.zip
ethpipe => xeth (eXtended ETHereum)
Diffstat (limited to 'ethpipe/config.go')
-rw-r--r--ethpipe/config.go33
1 files changed, 0 insertions, 33 deletions
diff --git a/ethpipe/config.go b/ethpipe/config.go
deleted file mode 100644
index bea5005b6..000000000
--- a/ethpipe/config.go
+++ /dev/null
@@ -1,33 +0,0 @@
-package ethpipe
-
-import "github.com/ethereum/go-ethereum/ethutil"
-
-var cnfCtr = ethutil.Hex2Bytes("661005d2720d855f1d9976f88bb10c1a3398c77f")
-
-type Config struct {
- pipe *Pipe
-}
-
-func (self *Config) Get(name string) *Object {
- configCtrl := self.pipe.World().safeGet(cnfCtr)
- var addr []byte
-
- switch name {
- case "NameReg":
- addr = []byte{0}
- case "DnsReg":
- objectAddr := configCtrl.GetStorage(ethutil.BigD([]byte{0}))
- domainAddr := (&Object{self.pipe.World().safeGet(objectAddr.Bytes())}).StorageString("DnsReg").Bytes()
- return &Object{self.pipe.World().safeGet(domainAddr)}
- default:
- addr = ethutil.RightPadBytes([]byte(name), 32)
- }
-
- objectAddr := configCtrl.GetStorage(ethutil.BigD(addr))
-
- return &Object{self.pipe.World().safeGet(objectAddr.Bytes())}
-}
-
-func (self *Config) Exist() bool {
- return self.pipe.World().Get(cnfCtr) != nil
-}