quoggles.auxiliary
Class Comparators

java.lang.Object
  |
  +--quoggles.auxiliary.Comparators

public class Comparators
extends java.lang.Object

Provides instances of Comparator that take two Numbers and compare them according to the type of each Comparator.


Nested Class Summary
private static class Comparators.FloatComparator
           
private static class Comparators.IntComparator
           
private static class Comparators.StringComparator
           
static class Comparators.TableComparator
          Used to compare a table (list of lists) according to the first sortByNr columns.
 
Constructor Summary
Comparators()
           
 
Method Summary
static java.util.Comparator getFloatingComparator()
          Returns an instance of Comparator that takes two Numbers and compares them according to their double representation.
static java.util.Comparator getIntegerComparator()
          Returns an instance of Comparator that takes two Numbers and compares them according to their integer representation.
static java.util.Comparator getStringComparator()
          Returns an instance of Comparator that takes two Numbers and compares them according to their double representation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Comparators

public Comparators()
Method Detail

getIntegerComparator

public static final java.util.Comparator getIntegerComparator()
Returns an instance of Comparator that takes two Numbers and compares them according to their integer representation.

Returns:

getFloatingComparator

public static final java.util.Comparator getFloatingComparator()
Returns an instance of Comparator that takes two Numbers and compares them according to their double representation.

Returns:

getStringComparator

public static final java.util.Comparator getStringComparator()
Returns an instance of Comparator that takes two Numbers and compares them according to their double representation.

Returns: