From 0ed1a8b50a9b9726cd57a2731d0405f6949c6188 Mon Sep 17 00:00:00 2001 From: obscuren Date: Fri, 31 Oct 2014 14:30:08 +0100 Subject: ethpipe => xeth (eXtended ETHereum) --- ethpipe/config.go | 33 --------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 ethpipe/config.go (limited to 'ethpipe/config.go') 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 -} -- cgit