Struct heron::rapier_plugin::rapier::ncollide::pipeline::object::CollisionObjectSlab [−][src]
A set of collision objects that can be indexed by collision object handles.
Implementations
impl<N, T> CollisionObjectSlab<N, T> where
N: RealField,
[src]
N: RealField,
pub fn new() -> CollisionObjectSlab<N, T>
[src]
Creates a new empty collection of collision objects.
pub fn with_capacity(capacity: usize) -> CollisionObjectSlab<N, T>
[src]
Constructs a new empty collection with the specified capacity.
pub fn insert(&mut self, co: CollisionObject<N, T>) -> CollisionObjectSlabHandle
[src]
Inserts a new collision object into this collection and returns the corresponding handle.
pub fn remove(
&mut self,
handle: CollisionObjectSlabHandle
) -> CollisionObject<N, T>
[src]
&mut self,
handle: CollisionObjectSlabHandle
) -> CollisionObject<N, T>
Removes from this collection the collision object identified by the given handle.
The removed collision object structure is returned.
pub fn get(
&self,
handle: CollisionObjectSlabHandle
) -> Option<&CollisionObject<N, T>>
[src]
&self,
handle: CollisionObjectSlabHandle
) -> Option<&CollisionObject<N, T>>
If it exists, retrieves a reference to the collision object identified by the given handle.
pub fn get_mut(
&mut self,
handle: CollisionObjectSlabHandle
) -> Option<&mut CollisionObject<N, T>>
[src]
&mut self,
handle: CollisionObjectSlabHandle
) -> Option<&mut CollisionObject<N, T>>
If it exists, retrieves a mutable reference to the collision object identified by the given handle.
pub fn get_pair_mut(
&mut self,
handle1: CollisionObjectSlabHandle,
handle2: CollisionObjectSlabHandle
) -> (Option<&mut CollisionObject<N, T>>, Option<&mut CollisionObject<N, T>>)
[src]
&mut self,
handle1: CollisionObjectSlabHandle,
handle2: CollisionObjectSlabHandle
) -> (Option<&mut CollisionObject<N, T>>, Option<&mut CollisionObject<N, T>>)
If they exists, retrieves a mutable reference to the two collision object identified by the given handles.
Panics if both handles are equal.
pub fn contains(&self, handle: CollisionObjectSlabHandle) -> bool
[src]
Returns true
if the specified handle identifies a collision object stored in this collection.
pub fn iter(&self) -> CollisionObjects<'_, N, T>ⓘNotable traits for CollisionObjects<'a, N, T>
impl<'a, N, T> Iterator for CollisionObjects<'a, N, T> where
T: 'a,
N: 'a + RealField, type Item = (CollisionObjectSlabHandle, &'a CollisionObject<N, T>);
[src]
Notable traits for CollisionObjects<'a, N, T>
impl<'a, N, T> Iterator for CollisionObjects<'a, N, T> where
T: 'a,
N: 'a + RealField, type Item = (CollisionObjectSlabHandle, &'a CollisionObject<N, T>);
Retrieves an iterator yielding references to each collision object.
pub fn iter_mut(&mut self) -> CollisionObjectsMut<'_, N, T>
[src]
Retrieves an iterator yielding references to each collision object.
pub fn len(&self) -> usize
[src]
The number of collision objects on this slab.
pub fn capacity(&self) -> usize
[src]
Return the number of values the slab can store without reallocating.
pub fn reserve(&mut self, additional: usize)
[src]
Reserve capacity for at least additional
more values to be stored
without allocating.
pub fn reserve_exact(&mut self, additional: usize)
[src]
Reserve the minimum capacity required to store exactly additional
more values.
Trait Implementations
impl<N, T> CollisionObjectSet<N> for CollisionObjectSlab<N, T> where
N: RealField,
[src]
N: RealField,
type CollisionObject = CollisionObject<N, T>
Type of the collision object stored into this set.
type CollisionObjectHandle = CollisionObjectSlabHandle
Type of the handles identifying collision objects.
pub fn collision_object(
&self,
handle: <CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObjectHandle
) -> Option<&<CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObject>
[src]
&self,
handle: <CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObjectHandle
) -> Option<&<CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObject>
pub fn foreach(
&self,
f: impl FnMut(<CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObjectHandle, &<CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObject)
)
[src]
&self,
f: impl FnMut(<CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObjectHandle, &<CollisionObjectSlab<N, T> as CollisionObjectSet<N>>::CollisionObject)
)
impl<N, T> Index<CollisionObjectSlabHandle> for CollisionObjectSlab<N, T> where
N: RealField,
[src]
N: RealField,
type Output = CollisionObject<N, T>
The returned type after indexing.
pub fn index(
&self,
handle: CollisionObjectSlabHandle
) -> &<CollisionObjectSlab<N, T> as Index<CollisionObjectSlabHandle>>::Output
[src]
&self,
handle: CollisionObjectSlabHandle
) -> &<CollisionObjectSlab<N, T> as Index<CollisionObjectSlabHandle>>::Output
impl<N, T> IndexMut<CollisionObjectSlabHandle> for CollisionObjectSlab<N, T> where
N: RealField,
[src]
N: RealField,
pub fn index_mut(
&mut self,
handle: CollisionObjectSlabHandle
) -> &mut <CollisionObjectSlab<N, T> as Index<CollisionObjectSlabHandle>>::Output
[src]
&mut self,
handle: CollisionObjectSlabHandle
) -> &mut <CollisionObjectSlab<N, T> as Index<CollisionObjectSlabHandle>>::Output
Auto Trait Implementations
impl<N, T> !RefUnwindSafe for CollisionObjectSlab<N, T>
[src]
impl<N, T> Send for CollisionObjectSlab<N, T> where
T: Send,
[src]
T: Send,
impl<N, T> Sync for CollisionObjectSlab<N, T> where
T: Sync,
[src]
T: Sync,
impl<N, T> Unpin for CollisionObjectSlab<N, T> where
N: Unpin,
T: Unpin,
[src]
N: Unpin,
T: Unpin,
impl<N, T> !UnwindSafe for CollisionObjectSlab<N, T>
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Any for T where
T: Any,
T: Any,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Component for T where
T: 'static + Send + Sync,
T: 'static + Send + Sync,
impl<T> Downcast for T where
T: Any,
T: Any,
pub fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
pub fn as_any(&self) -> &(dyn Any + 'static)
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
impl<T> DowncastSync for T where
T: Send + Sync + Any,
T: Send + Sync + Any,
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T> Resource for T where
T: 'static + Send + Sync,
T: 'static + Send + Sync,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
SS: SubsetOf<SP>,
pub fn to_subset(&self) -> Option<SS>
pub fn is_in_subset(&self) -> bool
pub fn to_subset_unchecked(&self) -> SS
pub fn from_subset(element: &SS) -> SP
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,