mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-04 10:16:28 +07:00
GitOrigin-RevId: 22a46c15d8900d8a31514846755a013f6a67ad42
12 lines
352 B
Java
12 lines
352 B
Java
// "Replace Stream API chain with loop" "true-preview"
|
|
|
|
import java.util.List;
|
|
import java.util.function.Function;
|
|
import java.util.stream.Collectors;
|
|
|
|
public class Main {
|
|
public void test(List<String> list) {
|
|
System.out.println(list.stream().map(list.size() < 10 ? String::trim : Function.identity()).colle<caret>ct(Collectors.toList()));
|
|
}
|
|
}
|