mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-27 00:41:51 +07:00
12 lines
290 B
Java
12 lines
290 B
Java
// "Use 'computeIfAbsent' method with functional argument" "false"
|
|
|
|
import java.util.*;
|
|
|
|
class Test {
|
|
public void test(Map<String, List<Integer>> map, String key) {
|
|
map.putIfAbsent(key, createList<caret>());
|
|
map.get(key).add(0);
|
|
}
|
|
|
|
private native List<Integer> createList();
|
|
} |