Struct ggez::event::Mod
[−]
[src]
pub struct Mod { /* fields omitted */ }
Methods
impl Mod
[src]
fn empty() -> Mod
Returns an empty set of flags.
fn all() -> Mod
Returns the set containing all flags.
fn bits(&self) -> u16
Returns the raw value of the flags currently stored.
fn from_bits(bits: u16) -> Option<Mod>
Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
fn from_bits_truncate(bits: u16) -> Mod
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
fn is_empty(&self) -> bool
Returns true
if no flags are currently stored.
fn is_all(&self) -> bool
Returns true
if all flags are currently set.
fn intersects(&self, other: Mod) -> bool
Returns true
if there are flags common to both self
and other
.
fn contains(&self, other: Mod) -> bool
Returns true
all of the flags in other
are contained within self
.
fn insert(&mut self, other: Mod)
Inserts the specified flags in-place.
fn remove(&mut self, other: Mod)
Removes the specified flags in-place.
fn toggle(&mut self, other: Mod)
Toggles the specified flags in-place.
Trait Implementations
impl Clone for Mod
[src]
fn clone(&self) -> Mod
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl PartialOrd<Mod> for Mod
[src]
fn partial_cmp(&self, __arg_0: &Mod) -> Option<Ordering>
fn lt(&self, __arg_0: &Mod) -> bool
fn le(&self, __arg_0: &Mod) -> bool
fn gt(&self, __arg_0: &Mod) -> bool
fn ge(&self, __arg_0: &Mod) -> bool
impl Eq for Mod
[src]
impl Copy for Mod
[src]
impl Not for Mod
[src]
impl BitAndAssign<Mod> for Mod
[src]
fn bitand_assign(&mut self, other: Mod)
Disables all flags disabled in the set.
impl Ord for Mod
[src]
impl FromIterator<Mod> for Mod
[src]
fn from_iter<T>(iterator: T) -> Mod where
T: IntoIterator<Item = Mod>,
T: IntoIterator<Item = Mod>,
impl Debug for Mod
[src]
impl BitXor<Mod> for Mod
[src]
type Output = Mod
fn bitxor(self, other: Mod) -> Mod
Returns the left flags, but with all the right flags toggled.
impl Sub<Mod> for Mod
[src]
type Output = Mod
fn sub(self, other: Mod) -> Mod
Returns the set difference of the two sets of flags.
impl BitOrAssign<Mod> for Mod
[src]
fn bitor_assign(&mut self, other: Mod)
Adds the set of flags.
impl BitXorAssign<Mod> for Mod
[src]
fn bitxor_assign(&mut self, other: Mod)
Toggles the set of flags.
impl Extend<Mod> for Mod
[src]
fn extend<T>(&mut self, iterator: T) where
T: IntoIterator<Item = Mod>,
T: IntoIterator<Item = Mod>,
impl SubAssign<Mod> for Mod
[src]
fn sub_assign(&mut self, other: Mod)
Disables all flags enabled in the set.
impl BitOr<Mod> for Mod
[src]
impl PartialEq<Mod> for Mod
[src]
fn eq(&self, __arg_0: &Mod) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Mod) -> bool
This method tests for !=
.
impl BitAnd<Mod> for Mod
[src]
type Output = Mod
fn bitand(self, other: Mod) -> Mod
Returns the intersection between the two sets of flags.