Package adams.flow.sink
Class PlotContainerSink.DoubleComparator
- java.lang.Object
-
- adams.flow.sink.PlotContainerSink.DoubleComparator
-
- All Implemented Interfaces:
Serializable
,Comparator<String>
- Enclosing class:
- PlotContainerSink
public static class PlotContainerSink.DoubleComparator extends Object implements Comparator<String>, Serializable
Comparator for doubles that are stored as string.- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description DoubleComparator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(String o1, String o2)
Compares the two strings representing two double values.-
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 o1, String o2)
Compares the two strings representing two double values.- Specified by:
compare
in interfaceComparator<String>
- Parameters:
o1
- the first doubleo2
- the second double- Returns:
- -1, 0, +1 if first double is less than, equal to or greater than the second double
-
-