Skip to content

Commit

Permalink
optimize code
Browse files Browse the repository at this point in the history
  • Loading branch information
mcy committed Nov 2, 2024
1 parent 4522bb8 commit 0ac2d8a
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import java.io.Serializable;

public class Tuple2<T1 extends Serializable, T2 extends Serializable> implements Serializable {
public class Tuple2<T1, T2> implements Serializable {
private static final long serialVersionUID = 1L;

private final T1 value1;
Expand All @@ -13,7 +13,7 @@ public Tuple2(T1 value1, T2 value2) {
this.value2 = value2;
}

public static <T1 extends Serializable, T2 extends Serializable> Tuple2<T1, T2> of(T1 value1, T2 value2) {
public static <T1, T2> Tuple2<T1, T2> of(T1 value1, T2 value2) {
return new Tuple2<>(value1, value2);
}

Expand Down

0 comments on commit 0ac2d8a

Please sign in to comment.