pub struct EstimatedVecDeque<T: EstimateSize> {
inner: VecDeque<T>,
heap_size: KvSize,
}
Fields§
§inner: VecDeque<T>
§heap_size: KvSize
Implementations§
source§impl<T: EstimateSize> EstimatedVecDeque<T>
impl<T: EstimateSize> EstimatedVecDeque<T>
pub fn pop_back(&mut self) -> Option<T>
pub fn pop_front(&mut self) -> Option<T>
pub fn push_back(&mut self, value: T)
pub fn push_front(&mut self, value: T)
pub fn get(&self, index: usize) -> Option<&T>
pub fn front(&self) -> Option<&T>
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Trait Implementations§
source§impl<T: EstimateSize> Default for EstimatedVecDeque<T>
impl<T: EstimateSize> Default for EstimatedVecDeque<T>
source§impl<T: EstimateSize> EstimateSize for EstimatedVecDeque<T>
impl<T: EstimateSize> EstimateSize for EstimatedVecDeque<T>
source§fn estimated_heap_size(&self) -> usize
fn estimated_heap_size(&self) -> usize
The estimated heap size of the current struct in bytes.
source§fn estimated_size(&self) -> usizewhere
Self: Sized,
fn estimated_size(&self) -> usizewhere
Self: Sized,
The estimated total size of the current struct in bytes, including the
estimated_heap_size
and the size of Self
.Auto Trait Implementations§
impl<T> !Freeze for EstimatedVecDeque<T>
impl<T> RefUnwindSafe for EstimatedVecDeque<T>where
T: RefUnwindSafe,
impl<T> Send for EstimatedVecDeque<T>where
T: Send,
impl<T> Sync for EstimatedVecDeque<T>where
T: Sync,
impl<T> Unpin for EstimatedVecDeque<T>where
T: Unpin,
impl<T> UnwindSafe for EstimatedVecDeque<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