pub enum HybridSet<T> {
SmallSet(Vec<T>),
LargeSet(BitVec<T>),
}Variants§
Implementations§
source§impl<T: Idx> HybridSet<T>
impl<T: Idx> HybridSet<T>
pub fn new() -> Self
pub fn is_empty(&self) -> bool
sourcepub fn insert(&mut self, elem: T) -> bool
pub fn insert(&mut self, elem: T) -> bool
Adds elem to this set, returns true if n was not already in this set.
pub fn remove(&mut self, elem: T) -> bool
pub fn iter(&self) -> HybridIter<'_, T> ⓘ
pub fn union(&mut self, other: &HybridSet<T>) -> bool
pub fn subtract(&mut self, other: &HybridSet<T>) -> bool
pub fn intersect(&mut self, other: &HybridSet<T>) -> bool
Trait Implementations§
Auto Trait Implementations§
impl<T> RefUnwindSafe for HybridSet<T>where
T: RefUnwindSafe,
impl<T> Send for HybridSet<T>where
T: Send,
impl<T> Sync for HybridSet<T>where
T: Sync,
impl<T> Unpin for HybridSet<T>where
T: Unpin,
impl<T> UnwindSafe for HybridSet<T>where
T: 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