Struct broccoli::container::TreeIndBase [−][src]
pub struct TreeIndBase<'a, N: Num, T> { /* fields omitted */ }
Expand description
This is a Vec<BBox<N,&'a mut T>>
under the hood
with the added guarentee that all the &'a mut T
point to the same slice.
From this struct a user can create a TreeInd
.
Implementations
Create a TreeIndBase
.
Examples
let mut aabbs = [ broccoli::bbox(broccoli::rect(0isize, 10, 0, 10), 0), ]; let mut base=broccoli::container::TreeIndBase::new(&mut aabbs,|a|a.rect); let mut tree = base.build();
Extra the internals of a TreeIndBase
.
Examples
let mut aabbs = [ broccoli::bbox(broccoli::rect(0isize, 10, 0, 10), 0), ]; let mut base=broccoli::container::TreeIndBase::new(&mut aabbs,|a|a.rect); let mut inner=base.into_inner(); let mut tree = broccoli::new(&mut inner); //We can make a tree using the internals, but we lost the guarentee //that all the `&'a mut T` belong to the same slice.
Auto Trait Implementations
impl<'a, N, T> RefUnwindSafe for TreeIndBase<'a, N, T> where
N: RefUnwindSafe,
T: RefUnwindSafe,
impl<'a, N, T> Send for TreeIndBase<'a, N, T> where
N: Send,
T: Send,
impl<'a, N, T> Sync for TreeIndBase<'a, N, T> where
N: Sync,
T: Sync,
impl<'a, N, T> Unpin for TreeIndBase<'a, N, T>
impl<'a, N, T> !UnwindSafe for TreeIndBase<'a, N, T>