triple_arena

Crates.iotriple_arena
lib.rstriple_arena
version0.13.0
sourcesrc
created_at2021-06-02 04:30:28.909045
updated_at2024-02-20 19:37:13.354668
descriptionRegular, Chain, Surjection, and Ordered Arenas supporting non-Clone types, deletion, and more
homepage
repositoryhttps://github.com/AaronKutch/triple_arena
max_upload_size
id405120
size371,114
Aaron Kutch (AaronKutch)

documentation

https://docs.rs/triple_arena

README

Triple Arena

Provides 4 very flexible arena types. All support non-Clone entry insertion and deletion. All are indexable with a P: Ptr generic, which contains an optional generation counter to check for invalidity (zero cost when omitted). no_std compatible.

  • Arena<P, T> is the basic unassociated and nonhereditary arena type
  • ChainArena<P, T> allows associating entries together into multiple linear or cyclic chains, representing an idealized doubly linked list stored on an arena
  • SurjectArena<P, K, V> is a special kind of union-find data structure that can associate key entries into nonhereditary sets with a common value entry
  • OrdArena<P, K, V> is a fusion between an ordered balanced tree and an arena. All entries are key and value pairs that are all ordered by the key. Hereditary and nonhereditary insertion is supported. Unlike most BTreeMaps and HashMaps, the P: Ptr references to entries are stable, and can be trivially reused for O(1) operations.
Commit count: 204

cargo fmt