orx_tree/
pinned_storage.rs

1use crate::{TreeVariant, aliases::N};
2use orx_split_vec::{PinnedVec, Recursive, SplitVec};
3
4/// Trait defining the underlying pinned vector storage of the tree.
5pub trait PinnedStorage: 'static {
6    /// The pinned vector for the given variant `V`.
7    type PinnedVec<V>: PinnedVec<N<V>>
8    where
9        V: TreeVariant;
10}
11
12/// The tree uses `SplitVec<N<V>, Recursive>` as the underlying storage.
13pub struct SplitRecursive;
14impl PinnedStorage for SplitRecursive {
15    type PinnedVec<V>
16        = SplitVec<N<V>, Recursive>
17    where
18        V: TreeVariant;
19}