Struct IntoIter
pub struct IntoIter<K, V, A: Allocator = Global> { pub(in ::collections::hash::map) base: IntoIter<K, V, A> }
An owning iterator over the entries of a HashMap.
This struct is created by the into_iter method on HashMap
(provided by the IntoIterator trait). See its documentation for more.
Example
use std::collections::HashMap;
let map = HashMap::from([
("a", 1),
]);
let iter = map.into_iter();
Fields
base: IntoIter<K, V, A>
Implementations
impl<K, V, A: Allocator> IntoIter<K, V, A>
fn iter(&self) -> Iter<'_, K, V>Returns an iterator of references over the remaining items.
Trait Implementations
impl<K, V> Default for IntoIter<K, V>
fn default() -> Self
impl<K, V, A: Allocator> ExactSizeIterator for IntoIter<K, V, A>
fn len(&self) -> usize
impl<K, V, A: Allocator> FusedIterator for IntoIter<K, V, A>
impl<K, V, A: Allocator> Iterator for IntoIter<K, V, A>
type Item = (K, V);fn next(&mut self) -> Option<(K, V)>fn size_hint(&self) -> (usize, Option<usize>)fn count(self) -> usizefn fold<B, F>(self, init: B, f: F) -> B where Self: Sized, F: FnMut(B, Self::Item) -> B,
impl<K: Debug, V: Debug, A: Allocator> Debug for IntoIter<K, V, A>
fn fmt(&self, f: &mut Formatter<'_>) -> Result