pub enum ElementPosition<E> {
Unassigned,
Assigned {
entity: E,
index: usize,
},
}Expand description
Position of an element within a list variable.
Variants§
Unassigned
Element is not assigned to any list.
Assigned
Element is at the given index within the entity’s list.
Implementations§
Source§impl<E> ElementPosition<E>
impl<E> ElementPosition<E>
Sourcepub fn is_unassigned(&self) -> bool
pub fn is_unassigned(&self) -> bool
Returns true if the element is unassigned.
Sourcepub fn is_assigned(&self) -> bool
pub fn is_assigned(&self) -> bool
Returns true if the element is assigned.
Trait Implementations§
Source§impl<E: Clone> Clone for ElementPosition<E>
impl<E: Clone> Clone for ElementPosition<E>
Source§fn clone(&self) -> ElementPosition<E>
fn clone(&self) -> ElementPosition<E>
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<E: Debug> Debug for ElementPosition<E>
impl<E: Debug> Debug for ElementPosition<E>
Source§impl<E: PartialEq> PartialEq for ElementPosition<E>
impl<E: PartialEq> PartialEq for ElementPosition<E>
impl<E: Eq> Eq for ElementPosition<E>
impl<E> StructuralPartialEq for ElementPosition<E>
Auto Trait Implementations§
impl<E> Freeze for ElementPosition<E>where
E: Freeze,
impl<E> RefUnwindSafe for ElementPosition<E>where
E: RefUnwindSafe,
impl<E> Send for ElementPosition<E>where
E: Send,
impl<E> Sync for ElementPosition<E>where
E: Sync,
impl<E> Unpin for ElementPosition<E>where
E: Unpin,
impl<E> UnwindSafe for ElementPosition<E>where
E: UnwindSafe,
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