Class LeafBucket


class LeafBucket extends InMemoryNoteBucket
A note tree holding only notes, with no subtrees. The leaf bucket contains on average less than 256 notes, all of whom share the same leading prefix. If a notes branch has less than 256 notes, the top level tree of the branch should be a LeafBucket. Once a notes branch has more than 256 notes, the root should be a FanoutBucket and the LeafBucket will appear only as a cell of a FanoutBucket. Entries within the LeafBucket are stored sorted by ObjectId, and lookup is performed using binary search. As the entry list should contain fewer than 256 elements, the average number of compares to find an element should be less than 8 due to the O(log N) lookup behavior. A LeafBucket must be parsed from a tree object by NoteParser.