1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//! Uses exposed/independent index allocator
//!
//! # Examples
//!
//! ```
//! use gen_vec::Index;
//! use gen_vec::exposed::{IndexAllocator, ExposedGenVec};
//!
//! let mut allocator: IndexAllocator = IndexAllocator::new();
//!
//! let index: Index = allocator.allocate();
//!
//! let mut vec: ExposedGenVec<i32> = ExposedGenVec::new();
//! vec.set(index, 5);
//! assert!(vec.contains(index));
//!
//! let value: Option<&i32> = vec.get(index);
//! assert_eq!(value, Some(&5));
//! ```

pub mod gen_vec;
pub use self::gen_vec::*;
pub mod index_allocator;
pub use self::index_allocator::*;