IteratorResultFuncExtension<T> extension
- on
-
- Iter<
T>
- Iter<
Methods
-
tryFind<
E extends Object> (Result< bool, E> f(T)) → Result<Option< T> , E> -
Available on Iter<
Applies function to the elements of iterator and returns the first true result or the first error.T> , provided by the IteratorResultFuncExtension extension -
tryFold<
U, E extends Object> (U initial, Result< U, E> f(U, T)) → Result<U, E> -
Available on Iter<
An iterator method that applies a function as long as it returns successfully, producing a single, final value.T> , provided by the IteratorResultFuncExtension extension -
tryForEach<
E extends Object> (Result< (), E> f(T)) → Result<(), E> -
Available on Iter<
An iterator method that applies a fallible function to each item in the iterator, stopping at the first error and returning that error.T> , provided by the IteratorResultFuncExtension extension -
tryReduce<
E extends Object> (Result< T, E> f(T, T)) → Result<Option< T> , E> -
Available on Iter<
Reduces the elements to a single one by repeatedly applying a reducing operation. If the closure returns a failure, the failure is propagated back to the caller immediately.T> , provided by the IteratorResultFuncExtension extension