Skip to content

Commit

Permalink
remove redundant final modifiers
Browse files Browse the repository at this point in the history
  • Loading branch information
Henry Coles committed Apr 19, 2021
1 parent afba928 commit 2ea07f4
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions pitest/src/main/java/org/pitest/functional/prelude/Prelude.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,28 +33,28 @@
public abstract class Prelude {

@SafeVarargs
public static final <A> And<A> and(final Predicate<A>... ps) {
public static <A> And<A> and(final Predicate<A>... ps) {
return new And<>(Arrays.asList(ps));
}

public static final <A> And<A> and(final Iterable<? extends Predicate<A>> ps) {
public static <A> And<A> and(final Iterable<? extends Predicate<A>> ps) {
return new And<>(ps);
}

public static final <A> Predicate<A> not(final Predicate<A> p) {
public static <A> Predicate<A> not(final Predicate<A> p) {
return p.negate();
}

@SafeVarargs
public static final <A> Or<A> or(final Predicate<A>... ps) {
public static <A> Or<A> or(final Predicate<A>... ps) {
return new Or<>(Arrays.asList(ps));
}

public static final <A> Or<A> or(final Iterable<Predicate<A>> ps) {
public static <A> Or<A> or(final Iterable<Predicate<A>> ps) {
return new Or<>(ps);
}

public static final <A> Consumer<A> accumulateTo(
public static <A> Consumer<A> accumulateTo(
final Collection<A> collection) {
return collection::add;

Expand All @@ -65,28 +65,28 @@ public static <A, B> Consumer<A> putToMap(final Map<A, B> map,
return key -> map.put(key, value);
}

public static final <A> Function<A, A> id() {
public static <A> Function<A, A> id() {
return a -> a;
}

public static final <A> Function<A, A> id(final Class<A> type) {
public static <A> Function<A, A> id(final Class<A> type) {
return id();
}

public static final <T> Consumer<T> println() {
public static <T> Consumer<T> println() {
return printlnTo(System.out);
}

public static final <T> Consumer<T> println(final Class<T> type) {
public static <T> Consumer<T> println(final Class<T> type) {
return println();
}

public static final <T> Consumer<T> printlnTo(final Class<T> type,
final PrintStream stream) {
public static <T> Consumer<T> printlnTo(final Class<T> type,
final PrintStream stream) {
return printlnTo(stream);
}

public static final <T> Consumer<T> printlnTo(final PrintStream stream) {
public static <T> Consumer<T> printlnTo(final PrintStream stream) {
return stream::println;
}

Expand Down

0 comments on commit 2ea07f4

Please sign in to comment.