File tree Expand file tree Collapse file tree 1 file changed +29
-1
lines changed
src/main/resources/META-INF/rewrite Expand file tree Collapse file tree 1 file changed +29
-1
lines changed Original file line number Diff line number Diff line change @@ -3458,7 +3458,7 @@ examples:
34583458
34593459 class A {
34603460 public static Predicate<String> isHelloPredicate() {
3461- return Predicate.isEqual("hello");
3461+ return Predicate.<String> isEqual("hello");
34623462 }
34633463 }
34643464 language: java
@@ -3998,6 +3998,34 @@ examples:
39983998 language: java
39993999 ---
40004000type : specs.openrewrite.org/v1beta/example
4001+ recipeName : org.openrewrite.java.migrate.guava.NoGuavaPredicatesInstanceOf
4002+ examples :
4003+ - description : ' `NoGuavaPredicatesInstanceOfTest#predicatesEqualToToPredicateIsEqual`'
4004+ sources :
4005+ - before : |
4006+ import java.util.Collection;
4007+
4008+ import com.google.common.base.Predicates;
4009+ import com.google.common.collect.Iterables;
4010+
4011+ class Test {
4012+ boolean test(Collection<Object> collection) {
4013+ return Iterables.all(collection, Predicates.instanceOf(String.class));
4014+ }
4015+ }
4016+ after: |
4017+ import java.util.Collection;
4018+
4019+ import com.google.common.collect.Iterables;
4020+
4021+ class Test {
4022+ boolean test(Collection<Object> collection) {
4023+ return Iterables.all(collection, String.class::isInstance);
4024+ }
4025+ }
4026+ language: java
4027+ ---
4028+ type : specs.openrewrite.org/v1beta/example
40014029recipeName : org.openrewrite.java.migrate.guava.NoGuavaPrimitiveAsList
40024030examples :
40034031- description : ' `NoGuavaPrimitiveAsListTest#replaceBoolean`'
You can’t perform that action at this time.
0 commit comments