pub struct JunctionSides { /* private fields */ }
Implementations§
Source§impl JunctionSides
impl JunctionSides
pub const NONE: JunctionSides
pub const CORNER_TOPLEFT: JunctionSides
pub const CORNER_TOPRIGHT: JunctionSides
pub const CORNER_BOTTOMLEFT: JunctionSides
pub const CORNER_BOTTOMRIGHT: JunctionSides
pub const TOP: JunctionSides
pub const BOTTOM: JunctionSides
pub const LEFT: JunctionSides
pub const RIGHT: JunctionSides
Sourcepub const fn empty() -> JunctionSides
pub const fn empty() -> JunctionSides
Returns an empty set of flags
Sourcepub const fn all() -> JunctionSides
pub const fn all() -> JunctionSides
Returns the set containing all flags.
Sourcepub fn from_bits(bits: u32) -> Option<JunctionSides>
pub fn from_bits(bits: u32) -> Option<JunctionSides>
Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
Sourcepub const fn from_bits_truncate(bits: u32) -> JunctionSides
pub const fn from_bits_truncate(bits: u32) -> JunctionSides
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
Sourcepub const unsafe fn from_bits_unchecked(bits: u32) -> JunctionSides
pub const unsafe fn from_bits_unchecked(bits: u32) -> JunctionSides
Convert from underlying bit representation, preserving all bits (even those not corresponding to a defined flag).
Sourcepub const fn intersects(&self, other: JunctionSides) -> bool
pub const fn intersects(&self, other: JunctionSides) -> bool
Returns true
if there are flags common to both self
and other
.
Sourcepub const fn contains(&self, other: JunctionSides) -> bool
pub const fn contains(&self, other: JunctionSides) -> bool
Returns true
all of the flags in other
are contained within self
.
Sourcepub fn insert(&mut self, other: JunctionSides)
pub fn insert(&mut self, other: JunctionSides)
Inserts the specified flags in-place.
Sourcepub fn remove(&mut self, other: JunctionSides)
pub fn remove(&mut self, other: JunctionSides)
Removes the specified flags in-place.
Sourcepub fn toggle(&mut self, other: JunctionSides)
pub fn toggle(&mut self, other: JunctionSides)
Toggles the specified flags in-place.
Sourcepub fn set(&mut self, other: JunctionSides, value: bool)
pub fn set(&mut self, other: JunctionSides, value: bool)
Inserts or removes the specified flags depending on the passed value.
Trait Implementations§
Source§impl Binary for JunctionSides
impl Binary for JunctionSides
Source§impl BitAnd for JunctionSides
impl BitAnd for JunctionSides
Source§fn bitand(self, other: JunctionSides) -> JunctionSides
fn bitand(self, other: JunctionSides) -> JunctionSides
Returns the intersection between the two sets of flags.
Source§type Output = JunctionSides
type Output = JunctionSides
&
operator.Source§impl BitAndAssign for JunctionSides
impl BitAndAssign for JunctionSides
Source§fn bitand_assign(&mut self, other: JunctionSides)
fn bitand_assign(&mut self, other: JunctionSides)
Disables all flags disabled in the set.
Source§impl BitOr for JunctionSides
impl BitOr for JunctionSides
Source§fn bitor(self, other: JunctionSides) -> JunctionSides
fn bitor(self, other: JunctionSides) -> JunctionSides
Returns the union of the two sets of flags.
Source§type Output = JunctionSides
type Output = JunctionSides
|
operator.Source§impl BitOrAssign for JunctionSides
impl BitOrAssign for JunctionSides
Source§fn bitor_assign(&mut self, other: JunctionSides)
fn bitor_assign(&mut self, other: JunctionSides)
Adds the set of flags.
Source§impl BitXor for JunctionSides
impl BitXor for JunctionSides
Source§fn bitxor(self, other: JunctionSides) -> JunctionSides
fn bitxor(self, other: JunctionSides) -> JunctionSides
Returns the left flags, but with all the right flags toggled.
Source§type Output = JunctionSides
type Output = JunctionSides
^
operator.Source§impl BitXorAssign for JunctionSides
impl BitXorAssign for JunctionSides
Source§fn bitxor_assign(&mut self, other: JunctionSides)
fn bitxor_assign(&mut self, other: JunctionSides)
Toggles the set of flags.
Source§impl Clone for JunctionSides
impl Clone for JunctionSides
Source§fn clone(&self) -> JunctionSides
fn clone(&self) -> JunctionSides
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for JunctionSides
impl Debug for JunctionSides
Source§impl Extend<JunctionSides> for JunctionSides
impl Extend<JunctionSides> for JunctionSides
Source§fn extend<T: IntoIterator<Item = JunctionSides>>(&mut self, iterator: T)
fn extend<T: IntoIterator<Item = JunctionSides>>(&mut self, iterator: T)
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
)Source§impl FromIterator<JunctionSides> for JunctionSides
impl FromIterator<JunctionSides> for JunctionSides
Source§fn from_iter<T: IntoIterator<Item = JunctionSides>>(
iterator: T,
) -> JunctionSides
fn from_iter<T: IntoIterator<Item = JunctionSides>>( iterator: T, ) -> JunctionSides
Source§impl<'a> FromValue<'a> for JunctionSides
impl<'a> FromValue<'a> for JunctionSides
unsafe fn from_value(value: &Value) -> Self
Source§impl<'a> FromValueOptional<'a> for JunctionSides
impl<'a> FromValueOptional<'a> for JunctionSides
unsafe fn from_value_optional(value: &Value) -> Option<Self>
Source§impl Hash for JunctionSides
impl Hash for JunctionSides
Source§impl LowerHex for JunctionSides
impl LowerHex for JunctionSides
Source§impl Not for JunctionSides
impl Not for JunctionSides
Source§fn not(self) -> JunctionSides
fn not(self) -> JunctionSides
Returns the complement of this set of flags.
Source§type Output = JunctionSides
type Output = JunctionSides
!
operator.Source§impl Octal for JunctionSides
impl Octal for JunctionSides
Source§impl Ord for JunctionSides
impl Ord for JunctionSides
Source§fn cmp(&self, other: &JunctionSides) -> Ordering
fn cmp(&self, other: &JunctionSides) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for JunctionSides
impl PartialEq for JunctionSides
Source§impl PartialOrd for JunctionSides
impl PartialOrd for JunctionSides
Source§impl StaticType for JunctionSides
impl StaticType for JunctionSides
Source§fn static_type() -> Type
fn static_type() -> Type
Self
.Source§impl Sub for JunctionSides
impl Sub for JunctionSides
Source§fn sub(self, other: JunctionSides) -> JunctionSides
fn sub(self, other: JunctionSides) -> JunctionSides
Returns the set difference of the two sets of flags.
Source§type Output = JunctionSides
type Output = JunctionSides
-
operator.Source§impl SubAssign for JunctionSides
impl SubAssign for JunctionSides
Source§fn sub_assign(&mut self, other: JunctionSides)
fn sub_assign(&mut self, other: JunctionSides)
Disables all flags enabled in the set.
Source§impl UpperHex for JunctionSides
impl UpperHex for JunctionSides
impl Copy for JunctionSides
impl Eq for JunctionSides
impl StructuralPartialEq for JunctionSides
Auto Trait Implementations§
impl Freeze for JunctionSides
impl RefUnwindSafe for JunctionSides
impl Send for JunctionSides
impl Sync for JunctionSides
impl Unpin for JunctionSides
impl UnwindSafe for JunctionSides
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> ToSendValue for T
impl<T> ToSendValue for T
Source§fn to_send_value(&self) -> SendValue
fn to_send_value(&self) -> SendValue
SendValue
clone of self
.