mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-03 20:33:31 +07:00
GitOrigin-RevId: cc40c33ea4729b0faaecefe3e67287ece06090bd
14 lines
290 B
Java
14 lines
290 B
Java
// "Replace iteration with bulk 'Collection.addAll()' call" "false"
|
|
import java.util.*;
|
|
|
|
public class Collect {
|
|
class Person {}
|
|
|
|
void collectNames(Iterable<Person> persons){
|
|
List<Person> names = new ArrayList<>();
|
|
persons.forEach(p -> {
|
|
names<caret>.add(p);
|
|
});
|
|
}
|
|
}
|