pub struct SortedGroups<G, E>{ /* private fields */ }
Implementations§
Source§impl<G, E> SortedGroups<G, E>
impl<G, E> SortedGroups<G, E>
pub fn new( elements: impl IntoIterator<Item = E>, group_from_element: impl Fn(&E) -> G, ) -> Self
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn get(&self, index: usize) -> Option<(&G, &E)>
pub fn groups_len(&self) -> usize
pub fn iter_groups(&self) -> impl Iterator<Item = (&G, &BTreeSet<E>)>
Source§impl<G, E> SortedGroups<G, E>
impl<G, E> SortedGroups<G, E>
pub fn iter(&self) -> SortedGroupsIter<'_, G, E> ⓘ
Trait Implementations§
Source§impl<G, E> Clone for SortedGroups<G, E>
impl<G, E> Clone for SortedGroups<G, E>
Source§fn clone(&self) -> SortedGroups<G, E>
fn clone(&self) -> SortedGroups<G, 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<G, E> Debug for SortedGroups<G, E>
impl<G, E> Debug for SortedGroups<G, E>
Source§impl<'a, G, E> IntoIterator for &'a SortedGroups<G, E>
impl<'a, G, E> IntoIterator for &'a SortedGroups<G, E>
Source§impl<G, E> PartialEq for SortedGroups<G, E>
impl<G, E> PartialEq for SortedGroups<G, E>
Auto Trait Implementations§
impl<G, E> Freeze for SortedGroups<G, E>
impl<G, E> RefUnwindSafe for SortedGroups<G, E>where
G: RefUnwindSafe,
E: RefUnwindSafe,
impl<G, E> Send for SortedGroups<G, E>
impl<G, E> Sync for SortedGroups<G, E>
impl<G, E> Unpin for SortedGroups<G, E>
impl<G, E> UnwindSafe for SortedGroups<G, E>where
G: RefUnwindSafe,
E: RefUnwindSafe,
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