[−][src]Struct legion::storage::PackedStorage
Stores a slice of components of type T
for each archetype.
Archetype slices are sorted according to the group that component T
belongs to.
Each slice may be packed into a single allocation to optimise for group-based access.
Trait Implementations
impl<'a, T: Component> ComponentStorage<'a, T> for PackedStorage<T>
[src]
type Iter = ComponentIter<'a, T>
An iterator of shared archetype slice references.
type IterMut = ComponentIterMut<'a, T>
An iterator of mutable archetype slice references.
unsafe fn extend_memcopy(
&mut self,
archetype: ArchetypeIndex,
ptr: *const T,
count: usize
)
[src]
&mut self,
archetype: ArchetypeIndex,
ptr: *const T,
count: usize
)
fn get(
&'a self,
ArchetypeIndex: ArchetypeIndex
) -> Option<ComponentSlice<'a, T>>
[src]
&'a self,
ArchetypeIndex: ArchetypeIndex
) -> Option<ComponentSlice<'a, T>>
unsafe fn get_mut(
&'a self,
ArchetypeIndex: ArchetypeIndex
) -> Option<ComponentSliceMut<'a, T>>
[src]
&'a self,
ArchetypeIndex: ArchetypeIndex
) -> Option<ComponentSliceMut<'a, T>>
fn iter(&'a self, start_inclusive: usize, end_exclusive: usize) -> Self::Iter
[src]
unsafe fn iter_mut(
&'a self,
start_inclusive: usize,
end_exclusive: usize
) -> Self::IterMut
[src]
&'a self,
start_inclusive: usize,
end_exclusive: usize
) -> Self::IterMut
fn len(&self) -> usize
[src]
fn is_empty(&self) -> bool
[src]
impl<T: Debug + Component> Debug for PackedStorage<T>
[src]
impl<T: Component> Default for PackedStorage<T>
[src]
impl<T: Component> Send for PackedStorage<T>
[src]
impl<T: Component> Sync for PackedStorage<T>
[src]
impl<T: Component> UnknownComponentStorage for PackedStorage<T>
[src]
fn move_component(
&mut self,
source: ArchetypeIndex,
index: ComponentIndex,
dst: ArchetypeIndex
)
[src]
&mut self,
source: ArchetypeIndex,
index: ComponentIndex,
dst: ArchetypeIndex
)
fn insert_archetype(&mut self, archetype: ArchetypeIndex, index: Option<usize>)
[src]
fn transfer_archetype(
&mut self,
src_archetype: ArchetypeIndex,
dst_archetype: ArchetypeIndex,
dst: &mut dyn UnknownComponentStorage
)
[src]
&mut self,
src_archetype: ArchetypeIndex,
dst_archetype: ArchetypeIndex,
dst: &mut dyn UnknownComponentStorage
)
fn transfer_component(
&mut self,
src_archetype: ArchetypeIndex,
src_component: ComponentIndex,
dst_archetype: ArchetypeIndex,
dst: &mut dyn UnknownComponentStorage
)
[src]
&mut self,
src_archetype: ArchetypeIndex,
src_component: ComponentIndex,
dst_archetype: ArchetypeIndex,
dst: &mut dyn UnknownComponentStorage
)
Moves a component to a new storage.
fn swap_remove(&mut self, archetype: ArchetypeIndex, index: ComponentIndex)
[src]
fn pack(&mut self, age_threshold: Epoch) -> usize
[src]
fn fragmentation(&self) -> f32
[src]
fn element_vtable(&self) -> ComponentMeta
[src]
fn get_raw(&self, ArchetypeIndex: ArchetypeIndex) -> Option<(*const u8, usize)>
[src]
unsafe fn get_mut_raw(
&self,
ArchetypeIndex: ArchetypeIndex
) -> Option<(*mut u8, usize)>
[src]
&self,
ArchetypeIndex: ArchetypeIndex
) -> Option<(*mut u8, usize)>
unsafe fn extend_memcopy_raw(
&mut self,
ArchetypeIndex: ArchetypeIndex,
ptr: *const u8,
count: usize
)
[src]
&mut self,
ArchetypeIndex: ArchetypeIndex,
ptr: *const u8,
count: usize
)
fn increment_epoch(&mut self)
[src]
fn ensure_capacity(&mut self, ArchetypeIndex: ArchetypeIndex, capacity: usize)
[src]
Auto Trait Implementations
impl<T> !RefUnwindSafe for PackedStorage<T>
impl<T> Unpin for PackedStorage<T>
impl<T> UnwindSafe for PackedStorage<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Downcast for T where
T: Any,
[src]
T: Any,
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
[src]
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
[src]
fn as_any(&self) -> &(dyn Any + 'static)
[src]
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
[src]
impl<T> DowncastSync for T where
T: Send + Sync + Any,
[src]
T: Send + Sync + Any,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
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.
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.
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>,