pub enum ElasticPopResult {
Empty,
Exact,
Upsampled(usize),
Downsampled(usize),
}
Expand description
Indicates what happened when the queue tried to satisfy the request for elements
Variants§
Empty
The buffer is completely empty, and so the default value is used
Exact
The buffer had enough elements to satisfy the request, but is still below the ideal max length threshold; and so no elements were dropped or duplicated
Upsampled(usize)
The buffer had some elements, but not enough to satisfy the request; some elements were repeated to fill the request; the value is how many “real” elements were present in the buffer
Downsampled(usize)
The buffer had more elements than the ideal max; some elements were dropped while filling the request; the value is how many “real” elements were removed from the queue
Trait Implementations§
Source§impl Clone for ElasticPopResult
impl Clone for ElasticPopResult
Source§fn clone(&self) -> ElasticPopResult
fn clone(&self) -> ElasticPopResult
Returns a copy 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 Debug for ElasticPopResult
impl Debug for ElasticPopResult
Source§impl Ord for ElasticPopResult
impl Ord for ElasticPopResult
Source§fn cmp(&self, other: &ElasticPopResult) -> Ordering
fn cmp(&self, other: &ElasticPopResult) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for ElasticPopResult
impl PartialEq for ElasticPopResult
Source§impl PartialOrd for ElasticPopResult
impl PartialOrd for ElasticPopResult
impl Copy for ElasticPopResult
impl Eq for ElasticPopResult
impl StructuralPartialEq for ElasticPopResult
Auto Trait Implementations§
impl Freeze for ElasticPopResult
impl RefUnwindSafe for ElasticPopResult
impl Send for ElasticPopResult
impl Sync for ElasticPopResult
impl Unpin for ElasticPopResult
impl UnwindSafe for ElasticPopResult
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