pub struct LinkedList { /* private fields */ }
Expand description
Doubly linked list
Implementations§
Source§impl LinkedList
impl LinkedList
Sourcepub fn with_capacity(capacity: usize) -> Self
pub fn with_capacity(capacity: usize) -> Self
Create a LinkedList with the given predicted capacity.
Sourcepub fn exist_near_head(&self, value: u64, search_limit: usize) -> bool
pub fn exist_near_head(&self, value: u64, search_limit: usize) -> bool
Whether the value exists closed (up to search_limit nodes) to the head of the list
Sourcepub fn remove(&mut self, index: usize) -> u64
pub fn remove(&mut self, index: usize) -> u64
Remove the node at the index, and return the value
Sourcepub fn iter(&self) -> LinkedListIter<'_> ⓘ
pub fn iter(&self) -> LinkedListIter<'_> ⓘ
Iterate over the list
Auto Trait Implementations§
impl Freeze for LinkedList
impl RefUnwindSafe for LinkedList
impl Send for LinkedList
impl Sync for LinkedList
impl Unpin for LinkedList
impl UnwindSafe for LinkedList
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