Answers for "java 8 group a collections by 2 property"

1

java 8 group a collections by 2 property

Map<String, Map<BlogPostType, List>> map = posts.stream()
  .collect(groupingBy(BlogPost::getAuthor, groupingBy(BlogPost::getType)));
Posted by: Guest on May-27-2020

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language