[][src]Trait treediff::Value

pub trait Value: PartialEq<Self> {
    type Key;
    type Item;
    fn items<'a>(
        &'a self
    ) -> Option<Box<dyn Iterator<Item = (Self::Key, &'a Self::Item)> + 'a>>; }

Represents a scalar value or an associative array.

Associated Types

type Key

The Key type used to find Values in a mapping.

type Item

The Value type itself.

Loading content...

Required methods

fn items<'a>(
    &'a self
) -> Option<Box<dyn Iterator<Item = (Self::Key, &'a Self::Item)> + 'a>>

Returns None if this is a scalar value, and an iterator yielding (Key, Value) pairs otherwise. It is entirely possible for it to yield no values though.

Loading content...

Implementors

Loading content...