The BTree package contains a class called DateTree for exactly that purpose. Works very well with huge collections of date intervals. Lukas On 12 October 2011 22:13, Paul DeBruicker <pdebruic@gmail.com> wrote:
Hi -
I am considering implementing a Centered Interval Tree (http://en.wikipedia.org/wiki/Interval_tree) because I have to get the set of Timespans a particular Timespan overlaps from an arbitrary set of Timespans.
In looking around I can only find the BTree implementation on SqueakSource, and the Left-Leaning-Red-Black-Tree linked to in the following list posting: http://forum.world.st/Interesting-survey-about-smalltalk-tp2261561p2263370.h...
Does Pharo either not need/benefit from the various kinds of trees?
Or is it trivial to implement/adapt the BTree to behave as a Red-Black Tree (or, in my case, the Centered Interval Tree) and as such I just need to learn how to do that?
Thanks
Paul
-- Lukas Renggli www.lukas-renggli.ch