Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion vavr/generator/Generator.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1670,7 +1670,7 @@ def generateMainClasses(): Unit = {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value >= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction0.java
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ static <R> CheckedFunction0<R> narrow(CheckedFunction0<? extends R> f) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction1.java
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ static <T> CheckedFunction1<T, T> identity() {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction2.java
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ default CheckedFunction1<T2, R> apply(T1 t1) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction3.java
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ default CheckedFunction1<T3, R> apply(T1 t1, T2 t2) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction4.java
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ default CheckedFunction1<T4, R> apply(T1 t1, T2 t2, T3 t3) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction5.java
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ default CheckedFunction1<T5, R> apply(T1 t1, T2 t2, T3 t3, T4 t4) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction6.java
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ default CheckedFunction1<T6, R> apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction7.java
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ default CheckedFunction1<T7, R> apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5, T6 t6)

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/CheckedFunction8.java
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ default CheckedFunction1<T8, R> apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5, T6 t6,

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function0.java
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ default R get() {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function1.java
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ static <T> Function1<T, T> identity() {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function2.java
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ default Function1<T2, R> apply(T1 t1) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function3.java
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ default Function1<T3, R> apply(T1 t1, T2 t2) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function4.java
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ default Function1<T4, R> apply(T1 t1, T2 t2, T3 t3) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function5.java
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ default Function1<T5, R> apply(T1 t1, T2 t2, T3 t3, T4 t4) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function6.java
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ default Function1<T6, R> apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function7.java
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ default Function1<T7, R> apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5, T6 t6) {

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
2 changes: 1 addition & 1 deletion vavr/src-gen/main/java/io/vavr/Function8.java
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ default Function1<T8, R> apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5, T6 t6, T7 t7)

/**
* Returns the number of function arguments.
* @return an int value >= 0
* @return an int value &gt;= 0
* @see <a href="http://en.wikipedia.org/wiki/Arity">Arity</a>
*/
default int arity() {
Expand Down
5 changes: 2 additions & 3 deletions vavr/src/main/java/io/vavr/control/Either.java
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,6 @@ default Option<Either<L, R>> filter(Predicate<? super R> predicate) {
* If the {@code Either} is a {@code Right} and the predicate doesn't match, the
* {@code Either} will be turned into a {@code Left} with contents computed by applying
* the filterVal function to the {@code Either} value.
* <p>
*
* <pre>{@code
* import static io.vavr.API.*;
Expand All @@ -466,11 +465,11 @@ default Option<Either<L, R>> filter(Predicate<? super R> predicate) {
* }</pre>
*
* @param predicate A predicate
* @param zero A function that turns a right value into a left value if the right value does not make it through the filter.
* @return an {@code Either} instance
* @throws NullPointerException if {@code predicate} is null
*/
default Either<L,R> filterOrElse(Predicate<? super R> predicate,
Function<? super R, ? extends L> zero) {
default Either<L,R> filterOrElse(Predicate<? super R> predicate, Function<? super R, ? extends L> zero) {
Objects.requireNonNull(predicate, "predicate is null");
Objects.requireNonNull(zero, "zero is null");
if (isLeft() || predicate.test(get())) {
Expand Down
6 changes: 2 additions & 4 deletions vavr/src/main/java/io/vavr/control/Try.java
Original file line number Diff line number Diff line change
Expand Up @@ -1009,11 +1009,9 @@ default Validation<Throwable, T> toValidation() {
* Converts this {@code Try} to a {@link Validation}, converting the Throwable (if present)
* to another object using passed {@link Function}.
*
* <pre>
* <code>
* <pre>{@code
* Validation<String, Integer> = Try.of(() -> 1/0).toValidation(Throwable::getMessage));
* </code>
* </pre>
* }</pre>
*
* @param <U> result type of the throwable mapper
* @param throwableMapper A transformation from throwable to desired invalid type of new {@code Validation}
Expand Down
2 changes: 1 addition & 1 deletion vavr/src/main/java/io/vavr/package-info.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/**
* The io.vavr package contains core types like {@linkplain io.vavr.Lambda}, {@linkplain io.vavr.Lazy} and {@linkplain io.vavr.Tuple}.
* Beside {@link io.vavr.API} the io.vavr package contains core types like (Checked)Functions and Tuples.
*/
package io.vavr;