[−][src]Struct ringui::enum_set::EnumSet
A specialized set implementation to use enum types.
It is a logic error for an item to be modified in such a way that the
transformation of the item to or from a usize, as determined by the
CLike trait, changes while the item is in the set. This is normally only
possible through Cell, RefCell, global state, I/O, or unsafe code.
Methods
impl<E: CLike> EnumSet<E>[src]
impl<E: CLike> EnumSet<E>pub fn new() -> EnumSet<E>[src]
pub fn new() -> EnumSet<E>Returns an empty EnumSet.
pub fn len(&self) -> usize[src]
pub fn len(&self) -> usizeReturns the number of elements in the given EnumSet.
pub fn is_empty(&self) -> bool[src]
pub fn is_empty(&self) -> boolReturns true if the EnumSet is empty.
pub fn clear(&mut self)[src]
pub fn clear(&mut self)pub fn is_disjoint(&self, other: &EnumSet<E>) -> bool[src]
pub fn is_disjoint(&self, other: &EnumSet<E>) -> boolReturns false if the EnumSet contains any enum of the given EnumSet.
pub fn is_superset(&self, other: &EnumSet<E>) -> bool[src]
pub fn is_superset(&self, other: &EnumSet<E>) -> boolReturns true if a given EnumSet is included in this EnumSet.
pub fn is_subset(&self, other: &EnumSet<E>) -> bool[src]
pub fn is_subset(&self, other: &EnumSet<E>) -> boolReturns true if this EnumSet is included in the given EnumSet.
pub fn union(&self, e: EnumSet<E>) -> EnumSet<E>[src]
pub fn union(&self, e: EnumSet<E>) -> EnumSet<E>Returns the union of both EnumSets.
pub fn intersection(&self, e: EnumSet<E>) -> EnumSet<E>[src]
pub fn intersection(&self, e: EnumSet<E>) -> EnumSet<E>Returns the intersection of both EnumSets.
pub fn insert(&mut self, e: E) -> bool[src]
pub fn insert(&mut self, e: E) -> boolAdds an enum to the EnumSet, and returns true if it wasn't there before
pub fn remove(&mut self, e: &E) -> bool[src]
pub fn remove(&mut self, e: &E) -> boolRemoves an enum from the EnumSet
pub fn contains(&self, e: &E) -> bool[src]
pub fn contains(&self, e: &E) -> boolReturns true if an EnumSet contains a given enum.
ⓘImportant traits for Iter<E>pub fn iter(&self) -> Iter<E>[src]
pub fn iter(&self) -> Iter<E>Returns an iterator over an EnumSet.
Trait Implementations
impl<E> PartialOrd<EnumSet<E>> for EnumSet<E>[src]
impl<E> PartialOrd<EnumSet<E>> for EnumSet<E>fn partial_cmp(&self, other: &EnumSet<E>) -> Option<Ordering>[src]
fn partial_cmp(&self, other: &EnumSet<E>) -> Option<Ordering>#[must_use]
fn lt(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]
fn lt(&self, other: &Rhs) -> boolThis method tests less than (for self and other) and is used by the < operator. Read more
#[must_use]
fn le(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]
fn le(&self, other: &Rhs) -> boolThis method tests less than or equal to (for self and other) and is used by the <= operator. Read more
#[must_use]
fn gt(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]
fn gt(&self, other: &Rhs) -> boolThis method tests greater than (for self and other) and is used by the > operator. Read more
#[must_use]
fn ge(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]
fn ge(&self, other: &Rhs) -> boolThis method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl<E> Ord for EnumSet<E>[src]
impl<E> Ord for EnumSet<E>fn cmp(&self, other: &EnumSet<E>) -> Ordering[src]
fn cmp(&self, other: &EnumSet<E>) -> Orderingfn max(self, other: Self) -> Self1.21.0[src]
fn max(self, other: Self) -> SelfCompares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self1.21.0[src]
fn min(self, other: Self) -> SelfCompares and returns the minimum of two values. Read more
impl<E> PartialEq<EnumSet<E>> for EnumSet<E>[src]
impl<E> PartialEq<EnumSet<E>> for EnumSet<E>fn eq(&self, other: &EnumSet<E>) -> bool[src]
fn eq(&self, other: &EnumSet<E>) -> bool#[must_use]
fn ne(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]
fn ne(&self, other: &Rhs) -> boolThis method tests for !=.
impl<E> Clone for EnumSet<E>[src]
impl<E> Clone for EnumSet<E>fn clone(&self) -> EnumSet<E>[src]
fn clone(&self) -> EnumSet<E>fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl<'a, E> IntoIterator for &'a EnumSet<E> where
E: CLike, [src]
impl<'a, E> IntoIterator for &'a EnumSet<E> where
E: CLike, type Item = E
The type of the elements being iterated over.
type IntoIter = Iter<E>
Which kind of iterator are we turning this into?
ⓘImportant traits for Iter<E>fn into_iter(self) -> Iter<E>[src]
fn into_iter(self) -> Iter<E>impl<E: CLike> Extend<E> for EnumSet<E>[src]
impl<E: CLike> Extend<E> for EnumSet<E>fn extend<I: IntoIterator<Item = E>>(&mut self, iter: I)[src]
fn extend<I: IntoIterator<Item = E>>(&mut self, iter: I)impl<'a, E: 'a + CLike + Copy> Extend<&'a E> for EnumSet<E>[src]
impl<'a, E: 'a + CLike + Copy> Extend<&'a E> for EnumSet<E>fn extend<I: IntoIterator<Item = &'a E>>(&mut self, iter: I)[src]
fn extend<I: IntoIterator<Item = &'a E>>(&mut self, iter: I)impl<E> Copy for EnumSet<E>[src]
impl<E> Copy for EnumSet<E>impl<E> Eq for EnumSet<E>[src]
impl<E> Eq for EnumSet<E>impl<E: CLike + Debug> Debug for EnumSet<E>[src]
impl<E: CLike + Debug> Debug for EnumSet<E>impl<E> Hash for EnumSet<E>[src]
impl<E> Hash for EnumSet<E>fn hash<H: Hasher>(&self, state: &mut H)[src]
fn hash<H: Hasher>(&self, state: &mut H)fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, Feeds a slice of this type into the given [Hasher]. Read more
impl<E: CLike> Sub<EnumSet<E>> for EnumSet<E>[src]
impl<E: CLike> Sub<EnumSet<E>> for EnumSet<E>type Output = EnumSet<E>
The resulting type after applying the - operator.
fn sub(self, e: EnumSet<E>) -> EnumSet<E>[src]
fn sub(self, e: EnumSet<E>) -> EnumSet<E>impl<E: CLike> BitAnd<EnumSet<E>> for EnumSet<E>[src]
impl<E: CLike> BitAnd<EnumSet<E>> for EnumSet<E>type Output = EnumSet<E>
The resulting type after applying the & operator.
fn bitand(self, e: EnumSet<E>) -> EnumSet<E>[src]
fn bitand(self, e: EnumSet<E>) -> EnumSet<E>impl<E: CLike> BitOr<EnumSet<E>> for EnumSet<E>[src]
impl<E: CLike> BitOr<EnumSet<E>> for EnumSet<E>type Output = EnumSet<E>
The resulting type after applying the | operator.
fn bitor(self, e: EnumSet<E>) -> EnumSet<E>[src]
fn bitor(self, e: EnumSet<E>) -> EnumSet<E>impl<E: CLike> BitXor<EnumSet<E>> for EnumSet<E>[src]
impl<E: CLike> BitXor<EnumSet<E>> for EnumSet<E>type Output = EnumSet<E>
The resulting type after applying the ^ operator.
fn bitxor(self, e: EnumSet<E>) -> EnumSet<E>[src]
fn bitxor(self, e: EnumSet<E>) -> EnumSet<E>impl<E: CLike> FromIterator<E> for EnumSet<E>[src]
impl<E: CLike> FromIterator<E> for EnumSet<E>fn from_iter<I: IntoIterator<Item = E>>(iter: I) -> EnumSet<E>[src]
fn from_iter<I: IntoIterator<Item = E>>(iter: I) -> EnumSet<E>impl<E> Serialize for EnumSet<E>[src]
impl<E> Serialize for EnumSet<E>fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer, [src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer, impl<'de, E> Deserialize<'de> for EnumSet<E>[src]
impl<'de, E> Deserialize<'de> for EnumSet<E>fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>, [src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>, Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>, [src]
impl<T, U> Into for T where
U: From<T>, impl<T> ToOwned for T where
T: Clone, [src]
impl<T> ToOwned for T where
T: Clone, impl<T> From for T[src]
impl<T> From for Timpl<T, U> TryFrom for T where
T: From<U>, [src]
impl<T, U> TryFrom for T where
T: From<U>, type Error = !
try_from)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>impl<T> Borrow for T where
T: ?Sized, [src]
impl<T> Borrow for T where
T: ?Sized, impl<T> Any for T where
T: 'static + ?Sized, [src]
impl<T> Any for T where
T: 'static + ?Sized, fn get_type_id(&self) -> TypeId[src]
fn get_type_id(&self) -> TypeIdimpl<T, U> TryInto for T where
U: TryFrom<T>, [src]
impl<T, U> TryInto for T where
U: TryFrom<T>, type Error = <U as TryFrom<T>>::Error
try_from)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>impl<T> BorrowMut for T where
T: ?Sized, [src]
impl<T> BorrowMut for T where
T: ?Sized, fn borrow_mut(&mut self) -> &mut T[src]
fn borrow_mut(&mut self) -> &mut Timpl<T> Scalar for T where
T: Copy + PartialEq<T> + Any + Debug, [src]
impl<T> Scalar for T where
T: Copy + PartialEq<T> + Any + Debug, impl<T> Same for T[src]
impl<T> Same for Ttype Output = T
Should always be Self
impl<SS, SP> SupersetOf for SP where
SS: SubsetOf<SP>, [src]
impl<SS, SP> SupersetOf for SP where
SS: SubsetOf<SP>, fn to_subset(&self) -> Option<SS>[src]
fn to_subset(&self) -> Option<SS>fn is_in_subset(&self) -> bool[src]
fn is_in_subset(&self) -> boolunsafe fn to_subset_unchecked(&self) -> SS[src]
unsafe fn to_subset_unchecked(&self) -> SSfn from_subset(element: &SS) -> SP[src]
fn from_subset(element: &SS) -> SPimpl<T> Any for T where
T: Any, [src]
impl<T> Any for T where
T: Any, fn get_type_id(&self) -> TypeId[src]
fn get_type_id(&self) -> TypeIdimpl<T> SetParameter for T[src]
impl<T> SetParameter for Tfn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>, [src]
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>, Sets value as a parameter of self.
impl<T> DeserializeOwned for T where
T: Deserialize<'de>, [src]
impl<T> DeserializeOwned for T where
T: Deserialize<'de>, impl<V> IntoVec for V[src]
impl<V> IntoVec for Vimpl<V> IntoPnt for V[src]
impl<V> IntoPnt for Vimpl<T> IntoPnt for T where
T: Scalar, [src]
impl<T> IntoPnt for T where
T: Scalar, impl<T> IntoPnt for T where
T: Scalar, [src]
impl<T> IntoPnt for T where
T: Scalar, impl<T> IntoPnt for T where
T: Scalar, [src]
impl<T> IntoPnt for T where
T: Scalar,