[Zodb-checkins] CVS: Zope/lib/python/BTrees - BucketTemplate.c:1.40
Tim Peters
tim.one@comcast.net
Wed, 12 Jun 2002 16:19:58 -0400
Update of /cvs-repository/Zope/lib/python/BTrees
In directory cvs.zope.org:/tmp/cvs-serv1303
Modified Files:
BucketTemplate.c
Log Message:
bucket_getstate(): Documented what it returns.
=== Zope/lib/python/BTrees/BucketTemplate.c 1.39 => 1.40 ===
}
+/*
+ * Return:
+ *
+ * For a set bucket (self->values is NULL), a one-tuple or two-tuple. The
+ * first element is a tuple of keys, of length self->len. The second element
+ * is the next bucket, present if and only if next is non-NULL:
+ *
+ * (
+ * (keys[0], keys[1], ..., keys[len-1]),
+ * <self->next iff non-NULL>
+ * )
+ *
+ * For a mapping bucket (self->values is not NULL), a one-tuple or two-tuple.
+ * The first element is a tuple interleaving keys and values, of length
+ * 2 * self->len. The second element is the next bucket, present iff next is
+ * non-NULL:
+ *
+ * (
+ * (keys[0], values[0], keys[1], values[1], ...,
+ * keys[len-1], values[len-1]),
+ * <self->next iff non-NULL>
+ * )
+ */
static PyObject *
bucket_getstate(Bucket *self, PyObject *args)
{