Skip to main content

AtomicPyTypeFlags

Struct AtomicPyTypeFlags 

Source
pub struct AtomicPyTypeFlags(/* private fields */);

Implementations§

Source§

impl AtomicPyTypeFlags

Source

pub fn from_bits_retain(bits: <AtomicU64 as Radium>::Item) -> Self

Source

pub fn from_element(element: <PyTypeFlags as IntoIterator>::Item) -> Self

Source

pub fn from_slice(slice: &[<PyTypeFlags as IntoIterator>::Item]) -> Self

Source

pub fn contains(&self, value: &<PyTypeFlags as IntoIterator>::Item) -> bool

Source

pub fn set(&self, value: <PyTypeFlags as IntoIterator>::Item, enabled: bool)

Source

pub fn insert(&self, value: <PyTypeFlags as IntoIterator>::Item) -> bool

Source

pub fn remove(&self, value: <PyTypeFlags as IntoIterator>::Item) -> bool

Source

pub fn toggle(&self, value: <PyTypeFlags as IntoIterator>::Item)

Source

pub fn first(&self) -> Option<<PyTypeFlags as IntoIterator>::Item>

Source

pub fn last(&self) -> Option<<PyTypeFlags as IntoIterator>::Item>

Source

pub fn pop_first(&self) -> Option<<PyTypeFlags as IntoIterator>::Item>

Source

pub fn pop_last(&self) -> Option<<PyTypeFlags as IntoIterator>::Item>

Source

pub fn retain(&self, f: impl FnMut(<PyTypeFlags as IntoIterator>::Item) -> bool)

Source

pub fn iter(&self) -> impl Iterator<Item = <PyTypeFlags as IntoIterator>::Item>

Source

pub fn iter_names( &self, ) -> impl Iterator<Item = (&'static str, <PyTypeFlags as IntoIterator>::Item)> + '_

Source

pub fn from_name(name: &str) -> Option<Self>

Source§

impl AtomicPyTypeFlags

Source

pub const fn new() -> Self

Source

pub const fn empty() -> Self

Source

pub fn as_bits(&self) -> &AtomicU64

Source

pub unsafe fn from_bits_unchecked(bits: <AtomicU64 as Radium>::Item) -> Self

Source

pub fn from_bits(bits: <AtomicU64 as Radium>::Item) -> Option<Self>

Source

pub fn from_bits_truncate(bits: <AtomicU64 as Radium>::Item) -> Self

Source

pub fn from_plain(set: PyTypeFlags) -> Self

Source

pub fn into_plain(self) -> PyTypeFlags

Source

pub fn swap_bits(&self, bits: &mut <AtomicU64 as Radium>::Item)

Source

pub fn all() -> Self

Source

pub fn is_all(&self) -> bool

Source

pub fn complement(&self) -> Self

Source

pub fn len(&self) -> usize

Source

pub fn is_empty(&self) -> bool

Source

pub fn clear(&self)

Source

pub fn is_subset(&self, other: &Self) -> bool

Source

pub fn is_superset(&self, other: &Self) -> bool

Source

pub fn is_disjoint(&self, other: &Self) -> bool

Source§

impl AtomicPyTypeFlags

Source

pub fn load(&self) -> PyTypeFlags

Source

pub fn has_feature(&self, flag: u8) -> bool

Source

pub fn replace_masked(&self, mask: PyTypeFlags, value: PyTypeFlags)

Replace mask bits with value & mask.

Source

pub fn remove_masked(&self, mask: PyTypeFlags)

Clear every bit set in mask.

Trait Implementations§

Source§

impl Binary for AtomicPyTypeFlags
where <AtomicU64 as Radium>::Item: Binary,

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl BitOrAssign<PyTypeFlags> for AtomicPyTypeFlags

Source§

fn bitor_assign(&mut self, rhs: PyTypeFlags)

Performs the |= operation. Read more
Source§

impl Debug for AtomicPyTypeFlags

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for AtomicPyTypeFlags

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Display for AtomicPyTypeFlags

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<&AtomicPyTypeFlags> for PyTypeFlags

Source§

fn from(value: &AtomicPyTypeFlags) -> Self

Converts to this type from the input type.
Source§

impl From<AtomicPyTypeFlags> for PyTypeFlags

Source§

fn from(value: AtomicPyTypeFlags) -> Self

Converts to this type from the input type.
Source§

impl From<PyTypeFlags> for AtomicPyTypeFlags

Source§

fn from(value: PyTypeFlags) -> Self

Converts to this type from the input type.
Source§

impl Index<<PyTypeFlags as IntoIterator>::Item> for AtomicPyTypeFlags

Source§

type Output = bool

The returned type after indexing.
Source§

fn index(&self, value: <PyTypeFlags as IntoIterator>::Item) -> &bool

Performs the indexing (container[index]) operation. Read more
Source§

impl LowerHex for AtomicPyTypeFlags

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Octal for AtomicPyTypeFlags
where <AtomicU64 as Radium>::Item: Octal,

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl UpperHex for AtomicPyTypeFlags

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T, U> ExactFrom<T> for U
where U: TryFrom<T>,

Source§

fn exact_from(value: T) -> U

Source§

impl<T, U> ExactInto<U> for T
where U: ExactFrom<T>,

Source§

fn exact_into(self) -> U

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Helper for T

Source§

impl<T, U> ImaginaryInto<U> for T
where U: ImaginaryFrom<T>,

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T, U> OverflowingInto<U> for T
where U: OverflowingFrom<T>,

Source§

impl<T> PrimitiveIntRandomBounds for T

Source§

impl<T> PrimitiveSignedRandomBounds for T

Source§

impl<T> PyThreadingConstraint for T

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T, U> RoundingInto<U> for T
where U: RoundingFrom<T>,

Source§

impl<T, U> SaturatingInto<U> for T
where U: SaturatingFrom<T>,

Source§

impl<T> ToBinaryString for T
where T: Binary,

Source§

fn to_binary_string(&self) -> String

Returns the String produced by Ts Binary implementation.

§Examples
use malachite_base::strings::ToBinaryString;

assert_eq!(5u64.to_binary_string(), "101");
assert_eq!((-100i16).to_binary_string(), "1111111110011100");
Source§

impl<T> ToCharString for T
where T: Display,

Source§

fn try_to_char_string(&self) -> Result<CharString, ToCharStringError>

Attempts to convert the value to a CharString. Read more
Source§

fn to_char_string(&self) -> CharString

Converts the value to a CharString. Read more
Source§

impl<T> ToCompactString for T
where T: Display,

Source§

impl<T> ToDebugString for T
where T: Debug,

Source§

fn to_debug_string(&self) -> String

Returns the String produced by Ts Debug implementation.

§Examples
use malachite_base::strings::ToDebugString;

assert_eq!([1, 2, 3].to_debug_string(), "[1, 2, 3]");
assert_eq!(
    [vec![2, 3], vec![], vec![4]].to_debug_string(),
    "[[2, 3], [], [4]]"
);
assert_eq!(Some(5).to_debug_string(), "Some(5)");
Source§

impl<T> ToLowerHexString for T
where T: LowerHex,

Source§

fn to_lower_hex_string(&self) -> String

Returns the String produced by Ts LowerHex implementation.

§Examples
use malachite_base::strings::ToLowerHexString;

assert_eq!(50u64.to_lower_hex_string(), "32");
assert_eq!((-100i16).to_lower_hex_string(), "ff9c");
Source§

impl<T> ToOctalString for T
where T: Octal,

Source§

fn to_octal_string(&self) -> String

Returns the String produced by Ts Octal implementation.

§Examples
use malachite_base::strings::ToOctalString;

assert_eq!(50u64.to_octal_string(), "62");
assert_eq!((-100i16).to_octal_string(), "177634");
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T> ToUpperHexString for T
where T: UpperHex,

Source§

fn to_upper_hex_string(&self) -> String

Returns the String produced by Ts UpperHex implementation.

§Examples
use malachite_base::strings::ToUpperHexString;

assert_eq!(50u64.to_upper_hex_string(), "32");
assert_eq!((-100i16).to_upper_hex_string(), "FF9C");
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T, U> WrappingInto<U> for T
where U: WrappingFrom<T>,

Source§

fn wrapping_into(self) -> U