Module fold

Source
Expand description

Provides utilities to fold [Stream]s and [TryStream]s with a short-circuited result.

Enums§

FoldResult
The result of folding a stream.
FoldWhile
Controls folding behavior.

Functions§

fold_while
Similar to [StreamExt::fold], but the closure f can short-circuit the operation by returning FoldWhile::Done.
try_fold_while
Similar to [TryStreamExt::try_fold], but the closure f can short-circuit the operation by returning FoldWhile::Done.