java obtain list string from list object

Solutions on MaxInterview for java obtain list string from list object by the best coders in the world

showing results for - "java obtain list string from list object"
Giorgio
03 Feb 2018
1List<String> ids = 
2  foos.stream().map(foo -> foo.getId()).collect(Collectors.toList());