mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-05-19 09:08:32 +07:00
18 lines
346 B
Java
18 lines
346 B
Java
// "Replace with collect" "true"
|
|
import java.util.*;
|
|
import java.util.stream.Collectors;
|
|
|
|
public abstract class Collect implements Collection<String>{
|
|
class Person {
|
|
String getName() {
|
|
return "";
|
|
}
|
|
}
|
|
|
|
void collectNames(List<Person> persons){
|
|
for (Person person : pers<caret>ons) {
|
|
add(person.getName());
|
|
}
|
|
}
|
|
}
|