Commit 71354250 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent b353d89c
...@@ -33,7 +33,7 @@ It is primarily used to verify ΔBTail in wcfs. ...@@ -33,7 +33,7 @@ It is primarily used to verify ΔBTail in wcfs.
- `AllStructs` generates all possible BTree topology structures with given keys. - `AllStructs` generates all possible BTree topology structures with given keys.
Topology encoding Topology encoding XXX values
----------------- -----------------
Topology encoding provides way to represent structure of a Tree as path-like string. Topology encoding provides way to represent structure of a Tree as path-like string.
...@@ -163,12 +163,13 @@ class Tree(object): ...@@ -163,12 +163,13 @@ class Tree(object):
# Bucket represents a bucket node. # Bucket represents a bucket node.
class Bucket(object): class Bucket(object):
# .keyv () of keys # .keyv () of keys
def __init__(b, *keyv): # .valuev None | () of values len(.valuev) == len(.keyv)
def __init__(b, *keyv): # XXX +values
_assertIncv(keyv) _assertIncv(keyv)
b.keyv = tuple(keyv) b.keyv = tuple(keyv)
def __hash__(b): def __hash__(b):
return hash(b.keyv) return hash(b.keyv) # XXX +values
def __ne__(a, b): def __ne__(a, b):
return not (a == b) return not (a == b)
def __eq__(a, b): def __eq__(a, b):
...@@ -176,7 +177,7 @@ class Bucket(object): ...@@ -176,7 +177,7 @@ class Bucket(object):
return False return False
return a.keyv == b.keyv return a.keyv == b.keyv
def __str__(b): def __str__(b): # XXX +values
return "B(" + ','.join(['%s' % _ for _ in b.keyv]) + ")" return "B(" + ','.join(['%s' % _ for _ in b.keyv]) + ")"
__repr__ = __str__ __repr__ = __str__
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment