pub struct PointerFlags(/* private fields */);Expand description
Flags to represent various characteristics of pointers
Implementations§
Source§impl PointerFlags
impl PointerFlags
Sourcepub const EMPTY: PointerFlags
pub const EMPTY: PointerFlags
An empty set of flags
Sourcepub const WEAK: PointerFlags
pub const WEAK: PointerFlags
Whether the pointer is weak (like std::sync::Weak)
Sourcepub const ATOMIC: PointerFlags
pub const ATOMIC: PointerFlags
Whether the pointer is atomic (like std::sync::Arc)
Sourcepub const LOCK: PointerFlags
pub const LOCK: PointerFlags
Whether the pointer is a lock (like std::sync::Mutex)
Sourcepub const fn empty() -> PointerFlags
pub const fn empty() -> PointerFlags
An empty set of flags.
Sourcepub const fn contains(self, other: PointerFlags) -> bool
pub const fn contains(self, other: PointerFlags) -> bool
Returns true if all flags in other are contained in self.
Sourcepub fn insert(&mut self, other: PointerFlags)
pub fn insert(&mut self, other: PointerFlags)
Inserts the flags in other into self.
Sourcepub fn remove(&mut self, other: PointerFlags)
pub fn remove(&mut self, other: PointerFlags)
Removes the flags in other from self.
Sourcepub const fn union(self, other: PointerFlags) -> PointerFlags
pub const fn union(self, other: PointerFlags) -> PointerFlags
Returns the union of self and other.
Sourcepub const fn intersection(self, other: PointerFlags) -> PointerFlags
pub const fn intersection(self, other: PointerFlags) -> PointerFlags
Returns the intersection of self and other.
Sourcepub const fn from_bits_retain(bits: u8) -> PointerFlags
pub const fn from_bits_retain(bits: u8) -> PointerFlags
Creates from raw bits (unchecked).
Trait Implementations§
Source§impl BitAnd for PointerFlags
impl BitAnd for PointerFlags
Source§type Output = PointerFlags
type Output = PointerFlags
The resulting type after applying the
& operator.Source§fn bitand(self, rhs: PointerFlags) -> PointerFlags
fn bitand(self, rhs: PointerFlags) -> PointerFlags
Performs the
& operation. Read moreSource§impl BitAndAssign for PointerFlags
impl BitAndAssign for PointerFlags
Source§fn bitand_assign(&mut self, rhs: PointerFlags)
fn bitand_assign(&mut self, rhs: PointerFlags)
Performs the
&= operation. Read moreSource§impl BitOr for PointerFlags
impl BitOr for PointerFlags
Source§type Output = PointerFlags
type Output = PointerFlags
The resulting type after applying the
| operator.Source§fn bitor(self, rhs: PointerFlags) -> PointerFlags
fn bitor(self, rhs: PointerFlags) -> PointerFlags
Performs the
| operation. Read moreSource§impl BitOrAssign for PointerFlags
impl BitOrAssign for PointerFlags
Source§fn bitor_assign(&mut self, rhs: PointerFlags)
fn bitor_assign(&mut self, rhs: PointerFlags)
Performs the
|= operation. Read moreSource§impl BitXor for PointerFlags
impl BitXor for PointerFlags
Source§type Output = PointerFlags
type Output = PointerFlags
The resulting type after applying the
^ operator.Source§fn bitxor(self, rhs: PointerFlags) -> PointerFlags
fn bitxor(self, rhs: PointerFlags) -> PointerFlags
Performs the
^ operation. Read moreSource§impl BitXorAssign for PointerFlags
impl BitXorAssign for PointerFlags
Source§fn bitxor_assign(&mut self, rhs: PointerFlags)
fn bitxor_assign(&mut self, rhs: PointerFlags)
Performs the
^= operation. Read moreSource§impl Clone for PointerFlags
impl Clone for PointerFlags
Source§fn clone(&self) -> PointerFlags
fn clone(&self) -> PointerFlags
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PointerFlags
impl Debug for PointerFlags
Source§impl Default for PointerFlags
impl Default for PointerFlags
Source§fn default() -> PointerFlags
fn default() -> PointerFlags
Returns the “default value” for a type. Read more
Source§impl Hash for PointerFlags
impl Hash for PointerFlags
Source§impl Not for PointerFlags
impl Not for PointerFlags
Source§type Output = PointerFlags
type Output = PointerFlags
The resulting type after applying the
! operator.Source§fn not(self) -> PointerFlags
fn not(self) -> PointerFlags
Performs the unary
! operation. Read moreSource§impl PartialEq for PointerFlags
impl PartialEq for PointerFlags
impl Copy for PointerFlags
impl Eq for PointerFlags
impl StructuralPartialEq for PointerFlags
Auto Trait Implementations§
impl Freeze for PointerFlags
impl RefUnwindSafe for PointerFlags
impl Send for PointerFlags
impl Sync for PointerFlags
impl Unpin for PointerFlags
impl UnwindSafe for PointerFlags
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