Skip to content

Commit

Permalink
Traversable.zipWithIndex() javadoc fix (#2706)
Browse files Browse the repository at this point in the history
  • Loading branch information
sleepytomcat authored and pivovarit committed Aug 19, 2024
1 parent 2e2373d commit 6ac4287
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions vavr/src/main/java/io/vavr/collection/Traversable.java
Original file line number Diff line number Diff line change
Expand Up @@ -1573,15 +1573,11 @@ default Number sum() {
Traversable<Tuple2<T, Integer>> zipWithIndex();

/**
* Returns a traversable formed from this traversable and another Iterable collection by mapping elements.
* If one of the two iterables is longer than the other, its remaining elements are ignored.
* <p>
* The length of the returned traversable is the minimum of the lengths of this traversable and {@code that}
* iterable.
* Zips this traversable with its indices by applying mapper provided.
*
* @param <U> The type of the mapped elements.
* @param <U> The type of the mapped elements.
* @param mapper a mapper.
* @return a new traversable containing mapped elements of this traversable and {@code that} iterable.
* @return a new traversable containing elements of this traversable, zipped with indices, and mapped with mapper provided.
* @throws NullPointerException if {@code mapper} is null
*/
<U> Traversable<U> zipWithIndex(BiFunction<? super T, ? super Integer, ? extends U> mapper);
Expand Down

0 comments on commit 6ac4287

Please # to comment.