Class SortPair

java.lang.Object
com.illumon.iris.db.tables.SortPair
All Implemented Interfaces:
Serializable

public class SortPair
extends Object
implements Serializable
A pair representing a column to sort by and its direction.
See Also:
Serialized Form
  • Field Details

  • Method Details

    • 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