changeset 1456:f7f9647ae5b7

BeDOZa: Implemented equals for KeyLists.
author Janus Dam Nielsen <janus.nielsen@alexandra.dk>
date Tue, 06 Jul 2010 10:56:30 +0200
parents 682f4b1d5f91
children f424bbdbce03
files viff/bedoza.py
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/viff/bedoza.py	Tue Jul 06 10:55:48 2010 +0200
+++ b/viff/bedoza.py	Tue Jul 06 10:56:30 2010 +0200
@@ -65,6 +65,9 @@
             keys.append(k1 + k2)
         return BeDOZaKeyList(keys)
 
+    def __eq__(self, other):
+        return self.alpha == other.alpha and self.keys == other.keys
+
     def __str__(self):
         return "(%s, %s)" % (self.alpha, str(self.keys))