Fast 32-bit value binary tree class based on the ebtree library from
HAProxy.
You need to have the library installed and link with -lebtree.
Usage example:
importocean.util.container.ebtree.EBTree64;
// Create a treeautotree = newEBTree32!();
// Add some values to the treefor ( uinti; i < 100; i++ )
{
tree.add(i);
}
// Get the lowest value in the treeautolowest = tree.first;
// Get the highest value in the treeautolowest = tree.last;
// Iterate over all nodes in the key whose values are <= 50foreach ( node; tree.lessEqual(50) )
{
// node value is node.key
}
// Empty the treetree.clear;
Boost Software License Version 1.0. See LICENSE_BOOST.txt for details.
Alternatively, this file may be distributed under the terms of the Tango
3-Clause BSD License (see LICENSE_BSD.txt for details).
Elastic binary tree class
Fast 32-bit value binary tree class based on the ebtree library from HAProxy.
You need to have the library installed and link with -lebtree.
Usage example: