Sequenced index
Boost.MultiIndex has a sequenced index feature: https://www.boost.org/doc/libs/1_88_0/libs/multi_index/doc/reference/seq_indices.html
This allows elements to be accessed in insertion order. It's useful for certain queue-like structures. If multi_index_map supported it, I would be able to remove an element by a key (Hash or BTree), even if that element is in the middle of the queue. Do you have any plans to support this feature?
Hi, yes I think this is actually fairly simple to implement. There is no "non-unique" version of a sequenced ordering, therefore it is simply a matter of swapping out the HashMap or BTreeMap lookup index for a Vec or VecDeque depending on what performance characteristics we want. I'll have a look when I have some time.
Thank you for your response. I'm currently using indexmap.
- https://docs.rs/indexmap/latest/indexmap/
- https://github.com/indexmap-rs/indexmap
However, having multiple indexes along with insertion order would clearly be much more powerful and useful.