Package org.swisspush.gateleen.core.util
Class CollectionContentComparator
- java.lang.Object
-
- org.swisspush.gateleen.core.util.CollectionContentComparator
-
- All Implemented Interfaces:
Comparator<String>
public class CollectionContentComparator extends Object implements Comparator<String>
This comparator allows you to sort a list to be compliant with the natural ordering of content returned by the storage. This may help you to create merged / manual created arrays for collections respecting the order as the storage does.- Author:
- https://github.com/ljucam [Mario Aerni]
-
-
Constructor Summary
Constructors Constructor Description CollectionContentComparator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompare(String c1, String c2)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
-
-
-
Method Detail
-
compare
public int compare(String c1, String c2)
- Specified by:
comparein interfaceComparator<String>
-
-