 titleListByLearningArea.put("Commerce", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("English", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("Health & PE", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("Humanities", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("Mathematics", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("Music & the Arts", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("Science", new ArrayList<TitleIsbnBean>() {}); titleListByLearningArea.put("Others", new ArrayList<TitleIsbnBean>() {});  titleListByLearningArea = nonPackageIsbnList.stream() .collect(Collectors.groupingBy(TitleIsbnBean::getKeylearningarea,                                 LinkedHashMap::new,Collectors.toList())