mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-21 04:50:58 +07:00
22 lines
401 B
Java
22 lines
401 B
Java
// "Apply conversion '.toArray(new Test.User[0])'" "true-preview"
|
|
|
|
import java.util.List;
|
|
|
|
class Test {
|
|
interface User {
|
|
|
|
}
|
|
|
|
interface Query {
|
|
|
|
List<?> getResultList();
|
|
}
|
|
|
|
public User[] getAllUsers(Query readQuery) {
|
|
List<?> result = readQuery.getResultList();
|
|
return (result != null) ? result.toAr<caret>ray() : new User[0];
|
|
}
|
|
|
|
public static void main(String[] args) {
|
|
}
|
|
} |