#btree-map #tree #indexing #index #b-tree

indextreemap

A BTreeMap implementation that allows for key and or positional insertion and retreival

4 releases

0.1.25 Dec 22, 2023
0.1.24 Dec 19, 2023
0.1.23 Jul 10, 2023
0.1.15 Jun 30, 2023

#159 in Memory management

Download history 1/week @ 2024-01-05 2/week @ 2024-01-12 14/week @ 2024-02-23 7/week @ 2024-03-01 16/week @ 2024-03-08 45/week @ 2024-03-15 128/week @ 2024-03-29 28/week @ 2024-04-05

156 downloads per month

MIT license

90KB
1.5K SLoC

indextreemap

IndexTreeMap is an ordered tree map based on the rust standard library BTreeMap, that allows for items to be accessed by key, value, or position in the tree.

This library is meant to serve niche use cases where the deterministic ordering of key-value items is required, with the ability to index items by position or key in logarithmic time.

When compared to the standard library BTreeMap (std::collections::BTreeMap), for operations that require changes in memory allocation (insert, remove, etc...) the IndexTreeMap is slower. However, when referencing data already allocated in memory, the IndexTreeMap is equivalent or faster.

Dependencies

~0.4–1MB
~24K SLoC