java stream get list of one field code example
Example: java stream get list of one field
List<String> names =
personList.stream()
.map(Person::getName)
.collect(Collectors.toList());
List<String> names =
personList.stream()
.map(Person::getName)
.collect(Collectors.toList());