View Source Iter.Iterable.FlatMapper (iterex v0.1.2)

An iterable which works like map/2 but flattens nested iterables.

Summary

Functions

Creates an iterable which works like map/2 but flattens nested iterables.

Types

@type mapper() :: (Iter.Iterable.t() -> Iter.Iterable.t() | Iter.Iterable.element())
@type t() :: %Iter.Iterable.FlatMapper{iterable: Iter.Iterable.t(), mapper: mapper()}

Functions

@spec new(Iter.Iterable.t(), mapper()) :: t()

Creates an iterable which works like map/2 but flattens nested iterables.