Struct ComponentIdSet
pub struct ComponentIdSet(/* private fields */);Expand description
A set of ComponentIds.
Implementations§
§impl ComponentIdSet
impl ComponentIdSet
pub const fn new() -> ComponentIdSet
pub const fn new() -> ComponentIdSet
Create a new empty ComponentIdSet.
pub fn insert(&mut self, index: ComponentId)
pub fn insert(&mut self, index: ComponentId)
Adds a ComponentId to the set.
pub fn remove(&mut self, index: ComponentId)
pub fn remove(&mut self, index: ComponentId)
Removes a ComponentId from the set.
pub fn clear(&mut self)
pub fn clear(&mut self)
Removes all ComponentIds from the set.
pub fn contains(&self, index: ComponentId) -> bool
pub fn contains(&self, index: ComponentId) -> bool
Returns true if the ComponentId is in the set.
pub fn is_disjoint(&self, other: &ComponentIdSet) -> bool
pub fn is_disjoint(&self, other: &ComponentIdSet) -> bool
Returns true if self has no elements in common with other. This
is equivalent to checking for an empty intersection.
pub fn is_subset(&self, other: &ComponentIdSet) -> bool
pub fn is_subset(&self, other: &ComponentIdSet) -> bool
Returns true if the set is a subset of another, i.e. other contains
at least all the values in self.
pub fn iter(&self) -> ComponentIdIter<Ones<'_>> ⓘ
pub fn iter(&self) -> ComponentIdIter<Ones<'_>> ⓘ
Iterates the ComponentIds in the set.
pub fn union<'a>(
&'a self,
other: &'a ComponentIdSet,
) -> ComponentIdIter<Union<'a>> ⓘ
pub fn union<'a>( &'a self, other: &'a ComponentIdSet, ) -> ComponentIdIter<Union<'a>> ⓘ
Returns a lazy iterator over the union of two ComponentIdSets.
pub fn intersection<'a>(
&'a self,
other: &'a ComponentIdSet,
) -> ComponentIdIter<Intersection<'a>> ⓘ
pub fn intersection<'a>( &'a self, other: &'a ComponentIdSet, ) -> ComponentIdIter<Intersection<'a>> ⓘ
Returns a lazy iterator over the intersection of two ComponentIdSets.
pub fn difference<'a>(
&'a self,
other: &'a ComponentIdSet,
) -> ComponentIdIter<Difference<'a>> ⓘ
pub fn difference<'a>( &'a self, other: &'a ComponentIdSet, ) -> ComponentIdIter<Difference<'a>> ⓘ
Returns a lazy iterator over the difference of two ComponentIdSets.
pub fn union_with(&mut self, other: &ComponentIdSet)
pub fn union_with(&mut self, other: &ComponentIdSet)
In-place union of two ComponentIdSets.
pub fn intersect_with(&mut self, other: &ComponentIdSet)
pub fn intersect_with(&mut self, other: &ComponentIdSet)
In-place intersection of two ComponentIdSets.
pub fn difference_with(&mut self, other: &ComponentIdSet)
pub fn difference_with(&mut self, other: &ComponentIdSet)
In-place difference of two ComponentIdSets.
pub fn difference_from(&mut self, other: &ComponentIdSet)
pub fn difference_from(&mut self, other: &ComponentIdSet)
In-place reversed difference of two ComponentIdSets.
This sets self to be other.difference(self).
Trait Implementations§
§impl Clone for ComponentIdSet
impl Clone for ComponentIdSet
§fn clone(&self) -> ComponentIdSet
fn clone(&self) -> ComponentIdSet
§fn clone_from(&mut self, source: &ComponentIdSet)
fn clone_from(&mut self, source: &ComponentIdSet)
source. Read more§impl Debug for ComponentIdSet
impl Debug for ComponentIdSet
§impl Default for ComponentIdSet
impl Default for ComponentIdSet
§fn default() -> ComponentIdSet
fn default() -> ComponentIdSet
§impl Extend<ComponentId> for ComponentIdSet
impl Extend<ComponentId> for ComponentIdSet
§fn extend<T>(&mut self, iter: T)where
T: IntoIterator<Item = ComponentId>,
fn extend<T>(&mut self, iter: T)where
T: IntoIterator<Item = ComponentId>,
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one)§impl From<ComponentIdSet> for AccessConflicts
impl From<ComponentIdSet> for AccessConflicts
§fn from(value: ComponentIdSet) -> AccessConflicts
fn from(value: ComponentIdSet) -> AccessConflicts
§impl FromIterator<ComponentId> for ComponentIdSet
impl FromIterator<ComponentId> for ComponentIdSet
§fn from_iter<T>(iter: T) -> ComponentIdSetwhere
T: IntoIterator<Item = ComponentId>,
fn from_iter<T>(iter: T) -> ComponentIdSetwhere
T: IntoIterator<Item = ComponentId>,
§impl Hash for ComponentIdSet
impl Hash for ComponentIdSet
§impl<'a> IntoIterator for &'a ComponentIdSet
impl<'a> IntoIterator for &'a ComponentIdSet
§type Item = ComponentId
type Item = ComponentId
§type IntoIter = ComponentIdIter<Ones<'a>>
type IntoIter = ComponentIdIter<Ones<'a>>
§fn into_iter(self) -> <&'a ComponentIdSet as IntoIterator>::IntoIter
fn into_iter(self) -> <&'a ComponentIdSet as IntoIterator>::IntoIter
§impl IntoIterator for ComponentIdSet
impl IntoIterator for ComponentIdSet
§type Item = ComponentId
type Item = ComponentId
§type IntoIter = ComponentIdIter<IntoOnes>
type IntoIter = ComponentIdIter<IntoOnes>
§fn into_iter(self) -> <ComponentIdSet as IntoIterator>::IntoIter
fn into_iter(self) -> <ComponentIdSet as IntoIterator>::IntoIter
§impl PartialEq for ComponentIdSet
impl PartialEq for ComponentIdSet
impl Eq for ComponentIdSet
impl StructuralPartialEq for ComponentIdSet
Auto Trait Implementations§
impl Freeze for ComponentIdSet
impl RefUnwindSafe for ComponentIdSet
impl Send for ComponentIdSet
impl Sync for ComponentIdSet
impl Unpin for ComponentIdSet
impl UnsafeUnpin for ComponentIdSet
impl UnwindSafe for ComponentIdSet
Blanket Implementations§
§impl<I> BidiIterator for I
impl<I> BidiIterator for I
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Conv for T
impl<T> Conv for T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSend for T
impl<T> DowncastSend for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> FmtForward for T
impl<T> FmtForward for T
§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
self to use its Binary implementation when Debug-formatted.§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
self to use its Display implementation when
Debug-formatted.§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
self to use its LowerExp implementation when
Debug-formatted.§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
self to use its LowerHex implementation when
Debug-formatted.§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
self to use its Octal implementation when Debug-formatted.§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
self to use its Pointer implementation when
Debug-formatted.§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
self to use its UpperExp implementation when
Debug-formatted.§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
self to use its UpperHex implementation when
Debug-formatted.§fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
§impl<T> FromTemplate for T
impl<T> FromTemplate for T
§impl<T> FromWorld for Twhere
T: Default,
impl<T> FromWorld for Twhere
T: Default,
§fn from_world(_world: &mut World) -> T
fn from_world(_world: &mut World) -> T
Creates Self using default().
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
§fn into_result(self) -> Result<T, RunSystemError>
fn into_result(self) -> Result<T, RunSystemError>
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self, then passes self.as_ref() into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self, then passes self.as_mut() into the pipe
function.§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self, then passes self.deref() into the pipe function.§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> Tap for T
impl<T> Tap for T
§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B> of a value. Read more§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B> of a value. Read more§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R> view of a value. Read more§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R> view of a value. Read more§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target of a value. Read more§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target of a value. Read more§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap() only in debug builds, and is erased in release builds.§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut() only in debug builds, and is erased in release
builds.§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow() only in debug builds, and is erased in release
builds.§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut() only in debug builds, and is erased in release
builds.§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref() only in debug builds, and is erased in release
builds.§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut() only in debug builds, and is erased in release
builds.§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref() only in debug builds, and is erased in release
builds.§impl<T> Template for T
impl<T> Template for T
§fn build_template(
&self,
_context: &mut TemplateContext<'_, '_>,
) -> Result<<T as Template>::Output, BevyError>
fn build_template( &self, _context: &mut TemplateContext<'_, '_>, ) -> Result<<T as Template>::Output, BevyError>
entity context to produce a Template::Output.§fn clone_template(&self) -> T
fn clone_template(&self) -> T
Clone.