pub struct OpBuilder<'a, T: 'a> { /* private fields */ }Expand description
Type used to acquire any number of slices and make a set operation on these slices.
Implementations§
Source§impl<'a, T> OpBuilder<'a, T>
impl<'a, T> OpBuilder<'a, T>
Sourcepub fn with_capacity(capacity: usize) -> Self
pub fn with_capacity(capacity: usize) -> Self
Construct an empty one with enough space for capacity elements or more.
Sourcepub fn from_vec(slices: Vec<&'a Set<T>>) -> Self
pub fn from_vec(slices: Vec<&'a Set<T>>) -> Self
Construct it with the content of the given slice.
Note that no other allocation than the one of the vec given in parameter is needed for the construction.
Sourcepub fn add(self, set: &'a Set<T>) -> Self
pub fn add(self, set: &'a Set<T>) -> Self
Add a new set that will be used for the future set operation and consume and return the type.
Sourcepub fn push(&mut self, set: &'a Set<T>)
pub fn push(&mut self, set: &'a Set<T>)
Push a new set that will be used for the future set operation.
Sourcepub fn intersection(self) -> Intersection<'a, T>
pub fn intersection(self) -> Intersection<'a, T>
Prepare the slices for the intersection set operation.
Sourcepub fn difference(self) -> Difference<'a, T>
pub fn difference(self) -> Difference<'a, T>
Prepare the slices for the difference set operation.
Sourcepub fn symmetric_difference(self) -> SymmetricDifference<'a, T>
pub fn symmetric_difference(self) -> SymmetricDifference<'a, T>
Prepare the slices for the symmetric difference set operation.
Trait Implementations§
Auto Trait Implementations§
impl<'a, T> Freeze for OpBuilder<'a, T>
impl<'a, T> RefUnwindSafe for OpBuilder<'a, T>where
T: RefUnwindSafe,
impl<'a, T> Send for OpBuilder<'a, T>where
T: Sync,
impl<'a, T> Sync for OpBuilder<'a, T>where
T: Sync,
impl<'a, T> Unpin for OpBuilder<'a, T>
impl<'a, T> UnwindSafe for OpBuilder<'a, T>where
T: 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