- java.lang.Object
-
- com.flexganttfx.model.util.ActivityComparator
-
- All Implemented Interfaces:
Comparator<Activity>
public final class ActivityComparator extends Object implements Comparator<Activity>
A specialized comparator used for sorting activities.
-
-
Constructor Summary
Constructors Constructor Description ActivityComparator()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(Activity activity1, Activity activity2)
static ActivityComparator
getInstance()
Returns the singleton instance of the comparator.-
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
-
getInstance
public static ActivityComparator getInstance()
Returns the singleton instance of the comparator.- Returns:
- the comparator singleton
-
compare
public int compare(Activity activity1, Activity activity2)
- Specified by:
compare
in interfaceComparator<Activity>
-
-