pub struct Cloner { /* private fields */ }
Expand description
Collects component types which can be cloned or copied
Populating such an object with all used component types is required to use World::clone
.
Implementations§
Source§impl Cloner
impl Cloner
Sourcepub fn add_cloneable<C>(&mut self)where
C: Clone + 'static,
pub fn add_cloneable<C>(&mut self)where
C: Clone + 'static,
Adds a component type which is cloneable
If C
is actually copyable, using add_copyable
is more efficient.
Sourcepub fn add_copyable<C>(&mut self)where
C: Copy + 'static,
pub fn add_copyable<C>(&mut self)where
C: Copy + 'static,
Adds a component type which is copyable
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Cloner
impl RefUnwindSafe for Cloner
impl Send for Cloner
impl Sync for Cloner
impl Unpin for Cloner
impl UnwindSafe for Cloner
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more