IntoKeyValuePairIterator

Trait IntoKeyValuePairIterator 

Source
pub trait IntoKeyValuePairIterator<AnnotatedT> {
    // Required method
    fn next(
        &mut self,
    ) -> Result<Option<(Variant<AnnotatedT>, Variant<AnnotatedT>)>, (MalformedError<AnnotatedT>, Variant<AnnotatedT>)>;
}
Expand description

Iterator of key-value pairs.

Required Methods§

Source

fn next( &mut self, ) -> Result<Option<(Variant<AnnotatedT>, Variant<AnnotatedT>)>, (MalformedError<AnnotatedT>, Variant<AnnotatedT>)>

Next.

Important: An error returned here does not mean that there are no more entries, just that the current iteration caused an error. Future ones might not. To exhaust the iterator, keep calling this function until it returns None.

Also note that the Err here is a tuple of the actual error with the value that caused it, so you likely won’t be able to use the ? operator directly on the result.

Implementors§

Source§

impl<AnnotatedT> IntoKeyValuePairIterator<AnnotatedT> for IntoKeyValuePairIteratorForBTreeMap<AnnotatedT>

Source§

impl<AnnotatedT> IntoKeyValuePairIterator<AnnotatedT> for IntoKeyValuePairIteratorForHashMap<AnnotatedT>

Source§

impl<InnerT, AnnotatedT> IntoKeyValuePairIterator<AnnotatedT> for IntoKeyValuePairIteratorForVariantIterator<InnerT, AnnotatedT>
where InnerT: Iterator<Item = Variant<AnnotatedT>>, AnnotatedT: Clone + Default,