pub struct ComponentColumn<'a> { /* private fields */ }
Expand description
Generic storage for the components inside Scene
.
This type generally doesn’t need to be interfaced with directly, as
define_system
can check and cast these into properly typed slices.
Implementations§
Source§impl ComponentColumn<'_>
impl ComponentColumn<'_>
Sourcepub fn component_type(&self) -> TypeId
pub fn component_type(&self) -> TypeId
Returns the type of the components contained in this struct.
Sourcepub fn get_mut<C: Any + Pod>(&mut self) -> Option<&mut [C]>
pub fn get_mut<C: Any + Pod>(&mut self) -> Option<&mut [C]>
If the TypeId
of C
is the same as
ComponentColumn::component_type
, returns a mutable borrow of the
components in this column.
This function generally doesn’t need to be interfaced with directly, as
define_system
is a straightforward wrapper for iterating through the
columns and calling this on the right one.
Auto Trait Implementations§
impl<'a> Freeze for ComponentColumn<'a>
impl<'a> RefUnwindSafe for ComponentColumn<'a>
impl<'a> Send for ComponentColumn<'a>
impl<'a> Sync for ComponentColumn<'a>
impl<'a> Unpin for ComponentColumn<'a>
impl<'a> !UnwindSafe for ComponentColumn<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more