Documentation of 'de.erichseifert.gral.data.comparators.Ascending' Java class
Ascending
de.erichseifert.gral.data.comparators

Class Ascending

    • Constructor Summary

      Constructors 
      Constructor and Description
      Ascending(int col)
      Creates a new Ascending object for sorting according to the specified column.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      int compare(Record record1, Record record2)
      Compares the values of two records at the specified column for order and returns a corresponding integer:
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Comparator

        comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
    • Constructor Detail

      • Ascending

        public Ascending(int col)
        Creates a new Ascending object for sorting according to the specified column.
        Parameters:
        col - Column index to be compared.
    • Method Detail

      • compare

        public int compare(Record record1,
                           Record record2)

        Compares the values of two records at the specified column for order and returns a corresponding integer:

        • a negative value means record1 is smaller than record2
        • 0 means record1 is equal to record2
        • a positive value means record1 is larger than record2
        Parameters:
        record1 - First record
        record2 - Second record
        Returns:
        An integer number describing the order: a negative value if record1 is smaller than record2, 0 if record1 is equal to record2, a positive value if record1 is larger than record2,

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.