mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-20 02:15:59 +07:00
11 lines
411 B
Java
11 lines
411 B
Java
// "Replace with 'computeIfAbsent' method call" "true"
|
|
import java.util.ArrayList;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
|
|
public class Test {
|
|
interface Shift {}
|
|
void foo(Map<String, List<Shift>> dayOfWeekAndShiftTypeToShiftListMap, String key){
|
|
List<Shift> dayOfWeekAndShiftTypeToShiftList = dayOfWeekAndShiftTypeToShiftListMap.computeIfAbsent(key, k -> new ArrayList<>((6) / 7));
|
|
}
|
|
} |