pub struct Unsorted<T> { /* private fields */ }
Expand description
A commutative data structure for lazily sorted sequences of data.
The sort does not occur until statistics need to be computed.
Note that this works on types that do not define a total ordering like
f32
and f64
. When an ordering is not defined, an arbitrary order
is returned.
Implementations§
Source§impl<T: PartialOrd> Unsorted<T>
impl<T: PartialOrd> Unsorted<T>
Source§impl<T: PartialOrd + Eq + Clone> Unsorted<T>
impl<T: PartialOrd + Eq + Clone> Unsorted<T>
pub fn cardinality(&mut self) -> usize
Source§impl<T: PartialOrd + Clone> Unsorted<T>
impl<T: PartialOrd + Clone> Unsorted<T>
Source§impl<T: PartialOrd + ToPrimitive> Unsorted<T>
impl<T: PartialOrd + ToPrimitive> Unsorted<T>
Trait Implementations§
Source§impl<T: PartialOrd> Commute for Unsorted<T>
impl<T: PartialOrd> Commute for Unsorted<T>
Source§impl<T: PartialOrd> Default for Unsorted<T>
impl<T: PartialOrd> Default for Unsorted<T>
Source§impl<T: PartialOrd> Extend<T> for Unsorted<T>
impl<T: PartialOrd> Extend<T> for Unsorted<T>
Source§fn extend<I: IntoIterator<Item = T>>(&mut self, it: I)
fn extend<I: IntoIterator<Item = T>>(&mut self, it: I)
Extends a collection with the contents of an iterator. Read more
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one
)Extends a collection with exactly one element.
Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one
)Reserves capacity in a collection for the given number of additional elements. Read more
Source§impl<T: PartialOrd> FromIterator<T> for Unsorted<T>
impl<T: PartialOrd> FromIterator<T> for Unsorted<T>
Auto Trait Implementations§
impl<T> Freeze for Unsorted<T>
impl<T> RefUnwindSafe for Unsorted<T>where
T: RefUnwindSafe,
impl<T> Send for Unsorted<T>where
T: Send,
impl<T> Sync for Unsorted<T>where
T: Sync,
impl<T> Unpin for Unsorted<T>where
T: Unpin,
impl<T> UnwindSafe for Unsorted<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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)