sort 2 object with stream sorted java code example
Example: java stream order by property
List<String> sorted = original.stream().sorted((o1,o2)-> o1.compareTo(o2)).collect(Collectors.toList());
List<String> sorted = original.stream().sorted((o1,o2)-> o1.compareTo(o2)).collect(Collectors.toList());