+ def reset(self) :
+ self.registry = {}
+
+ def __repr__(self) :
+ out = StringIO()
+ keys = self.registry.keys()
+ keys.sort()
+ for k in keys :
+ print >> out, "event", k
+ for listener in self.registry[k].keys() :
+ print >> out, listener.__name__
+ out.seek(0)
+ return out.read()
+
+