Class SortPair

java.lang.Object
io.deephaven.engine.table.impl.SortPair

public class SortPair extends Object
A pair representing a column to sort by and its direction.
  • Field Details

    • ZERO_LENGTH_SORT_PAIR_ARRAY

      public static SortPair[] ZERO_LENGTH_SORT_PAIR_ARRAY
  • Method Details

    • from

      public static SortPair[] from(Collection<SortColumn> sortColumns)
    • of

      public static SortPair of(SortColumn sortColumn)
    • ascending

      public static SortPair ascending(String name)
      Create an ascending SortPair for name.
      Parameters:
      name - the column name to sort by
      Returns:
      an ascending SortPair for name
    • ascendingPairs

      public static SortPair[] ascendingPairs(String... names)
      Create an array of ascending SortPair for names.
      Parameters:
      names - the column names to sort by
      Returns:
      an ascending SortPair array for names
    • descending

      public static SortPair descending(String name)
      Create an descending SortPair for name.
      Parameters:
      name - the column name to sort by
      Returns:
      an descending SortPair for name
    • descendingPairs

      public static SortPair[] descendingPairs(String... names)
      Create an array of descending SortPair for names.
      Parameters:
      names - the column names to sort by
      Returns:
      an descending SortPair array for names
    • getColumn

      public String getColumn()
      Returns:
      the column name for this SortPair.
    • getOrder

      public SortingOrder getOrder()
      Returns:
      the SortingOrder for this pair.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object