Struct bee_tangle::flags::Flags [−][src]
pub struct Flags { /* fields omitted */ }Flags representing the state of a message.
Implementations
impl Flags[src]
impl Flags[src]pub const REFERENCED: Flags[src]
pub const REFERENCED: Flags[src]The message has been referenced by a milestone.
pub fn from_bits(bits: u8) -> Option<Flags>[src]
pub fn from_bits(bits: u8) -> Option<Flags>[src]Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
pub const fn from_bits_truncate(bits: u8) -> Flags[src]
pub const fn from_bits_truncate(bits: u8) -> Flags[src]Convert from underlying bit representation, dropping any bits that do not correspond to flags.
pub const unsafe fn from_bits_unchecked(bits: u8) -> Flags[src]
pub const unsafe fn from_bits_unchecked(bits: u8) -> Flags[src]Convert from underlying bit representation, preserving all bits (even those not corresponding to a defined flag).
pub const fn intersects(&self, other: Flags) -> bool[src]
pub const fn intersects(&self, other: Flags) -> bool[src]Returns true if there are flags common to both self and other.
impl Flags[src]
impl Flags[src]pub fn is_milestone(&self) -> bool[src]
pub fn is_milestone(&self) -> bool[src]Return whether the flags indicate that the message is a milestone.
pub fn set_milestone(&mut self, is_milestone: bool)[src]
pub fn set_milestone(&mut self, is_milestone: bool)[src]Set the milestone flag for this message.
pub fn is_referenced(&self) -> bool[src]
pub fn is_referenced(&self) -> bool[src]Return whether the flags indicate that the message is referenced.
pub fn set_referenced(&mut self, is_referenced: bool)[src]
pub fn set_referenced(&mut self, is_referenced: bool)[src]Set the referenced flag for this message.
pub fn was_requested(&self) -> bool[src]
pub fn was_requested(&self) -> bool[src]Return whether the flags indicate that the message was requested.
pub fn set_requested(&mut self, was_requested: bool)[src]
pub fn set_requested(&mut self, was_requested: bool)[src]Set the valid flag for this message.
Trait Implementations
impl BitAndAssign<Flags> for Flags[src]
impl BitAndAssign<Flags> for Flags[src]fn bitand_assign(&mut self, other: Flags)[src]
fn bitand_assign(&mut self, other: Flags)[src]Disables all flags disabled in the set.
impl BitOrAssign<Flags> for Flags[src]
impl BitOrAssign<Flags> for Flags[src]fn bitor_assign(&mut self, other: Flags)[src]
fn bitor_assign(&mut self, other: Flags)[src]Adds the set of flags.
impl BitXorAssign<Flags> for Flags[src]
impl BitXorAssign<Flags> for Flags[src]fn bitxor_assign(&mut self, other: Flags)[src]
fn bitxor_assign(&mut self, other: Flags)[src]Toggles the set of flags.
impl Extend<Flags> for Flags[src]
impl Extend<Flags> for Flags[src]fn extend<T: IntoIterator<Item = Flags>>(&mut self, iterator: T)[src]
fn extend<T: IntoIterator<Item = Flags>>(&mut self, iterator: T)[src]Extends a collection with the contents of an iterator. Read more
fn extend_one(&mut self, item: A)[src]
fn extend_one(&mut self, item: A)[src]extend_one)Extends a collection with exactly one element.
fn extend_reserve(&mut self, additional: usize)[src]
fn extend_reserve(&mut self, additional: usize)[src]extend_one)Reserves capacity in a collection for the given number of additional elements. Read more
impl FromIterator<Flags> for Flags[src]
impl FromIterator<Flags> for Flags[src]impl Ord for Flags[src]
impl Ord for Flags[src]impl Packable for Flags[src]
impl Packable for Flags[src]fn packed_len(&self) -> usize[src]
fn packed_len(&self) -> usize[src]Returns the length of the packed bytes.
fn pack<W: Write>(&self, writer: &mut W) -> Result<(), Self::Error>[src]
fn pack<W: Write>(&self, writer: &mut W) -> Result<(), Self::Error>[src]Packs the instance to bytes and writes them to the passed writer.
fn unpack_inner<R: Read + ?Sized, const CHECK: bool>(
reader: &mut R
) -> Result<Self, Self::Error>[src]
fn unpack_inner<R: Read + ?Sized, const CHECK: bool>(
reader: &mut R
) -> Result<Self, Self::Error>[src]Reads bytes from the passed reader and unpacks them into an instance.
fn pack_new(&self) -> Vec<u8, Global>[src]
fn pack_new(&self) -> Vec<u8, Global>[src]Packs the instance to bytes and writes them to a newly allocated vector.
impl PartialOrd<Flags> for Flags[src]
impl PartialOrd<Flags> for Flags[src]fn partial_cmp(&self, other: &Flags) -> Option<Ordering>[src]
fn partial_cmp(&self, other: &Flags) -> Option<Ordering>[src]This method returns an ordering between self and other values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool1.0.0[src]This 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) -> bool1.0.0[src]This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
impl SubAssign<Flags> for Flags[src]
impl SubAssign<Flags> for Flags[src]fn sub_assign(&mut self, other: Flags)[src]
fn sub_assign(&mut self, other: Flags)[src]Disables all flags enabled in the set.
impl Copy for Flags[src]
impl Eq for Flags[src]
impl StructuralEq for Flags[src]
impl StructuralPartialEq for Flags[src]
Auto Trait Implementations
impl RefUnwindSafe for Flags
impl Send for Flags
impl Sync for Flags
impl Unpin for Flags
impl UnwindSafe for Flags
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]pub fn borrow_mut(&mut self) -> &mut T[src]
pub fn borrow_mut(&mut self) -> &mut T[src]Mutably borrows from an owned value. Read more
impl<T> CallHasher for T where
T: Hash,
impl<T> CallHasher for T where
T: Hash, impl<T> Same<T> for T
impl<T> Same<T> for Ttype Output = T
type Output = TShould always be Self
impl<T> ToOwned for T where
T: Clone, [src]
impl<T> ToOwned for T where
T: Clone, [src]type Owned = T
type Owned = TThe resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn to_owned(&self) -> T[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)[src]
pub fn clone_into(&self, target: &mut T)[src]🔬 This is a nightly-only experimental API. (toowned_clone_into)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,