aboutsummaryrefslogtreecommitdiffstats
path: root/ethchain/state.go
diff options
context:
space:
mode:
Diffstat (limited to 'ethchain/state.go')
-rw-r--r--ethchain/state.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/ethchain/state.go b/ethchain/state.go
index e209e0e2f..5af748e00 100644
--- a/ethchain/state.go
+++ b/ethchain/state.go
@@ -49,6 +49,11 @@ func (s *State) Purge() int {
return s.trie.NewIterator().Purge()
}
+func (s *State) EachStorage(cb ethutil.EachCallback) {
+ it := s.trie.NewIterator()
+ it.Each(cb)
+}
+
func (s *State) GetStateObject(addr []byte) *StateObject {
data := s.trie.Get(string(addr))
if data == "" {