pub struct QueueVec<E> { /* private fields */ }
Implementations§
Source§impl<E: Element> QueueVec<E>
impl<E: Element> QueueVec<E>
pub fn new() -> Self
pub fn with_num_elements(num_elements: usize) -> Self
pub fn with_elements( values: impl IntoIterator<Item = E> + ExactSizeIterator, ) -> Self
Trait Implementations§
Source§impl<E: Element + 'static> HasPeekBehavior<E> for QueueVec<E>
impl<E: Element + 'static> HasPeekBehavior<E> for QueueVec<E>
Source§impl<E: Element + 'static> QueueBehavior<E> for QueueVec<E>
impl<E: Element + 'static> QueueBehavior<E> for QueueVec<E>
Source§fn offer(&mut self, e: E) -> Result<()>
fn offer(&mut self, e: E) -> Result<()>
The specified element will be inserted into this queue,
if the queue can be executed immediately without violating the capacity limit.
容量制限に違反せずにすぐ実行できる場合は、指定された要素をこのキューに挿入します。
容量制限に違反せずにすぐ実行できる場合は、指定された要素をこのキューに挿入します。
Source§fn poll(&mut self) -> Result<Option<E>>
fn poll(&mut self) -> Result<Option<E>>
Retrieves and deletes the head of the queue. Returns None if the queue is empty.
キューの先頭を取得および削除します。キューが空の場合は None を返します。
キューの先頭を取得および削除します。キューが空の場合は None を返します。
Auto Trait Implementations§
impl<E> Freeze for QueueVec<E>
impl<E> RefUnwindSafe for QueueVec<E>
impl<E> Send for QueueVec<E>where
E: Send,
impl<E> Sync for QueueVec<E>where
E: Send,
impl<E> Unpin for QueueVec<E>
impl<E> UnwindSafe for QueueVec<E>
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