Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

java stream sort Collator

Collator coll = Collator.getInstance(new Locale("tr","TR"));
coll.setStrength(Collator.PRIMARY);
List<AClass> sorted = names.stream()
                           .sorted(Comparator.comparing(AClass::getName,coll))
                           .collect(Collectors.toList());
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #java #stream #sort #Collator
ADD COMMENT
Topic
Name
8+7 =