uk.ac.starlink.topcat
Class SortOrder

java.lang.Object
  extended by uk.ac.starlink.topcat.SortOrder

public class SortOrder
extends Object

Defines a sorting order for a table. An instance of this class defines the algorithm by which a sort is done, not rather than a given row sequence.

Currently, the sort order is defined only by the column that the table is sorted on, but this may get extended one day. Note that the sense (up or down) of the sort is selected separately than by this object.

Since:
23 Feb 2004
Author:
Mark Taylor (Starlink)

Field Summary
static SortOrder NONE
          SortOrder instance indicating the natural order of the data.
 
Constructor Summary
SortOrder(TableColumn tcol)
          Constructs a new sort order based on a table column.
 
Method Summary
 boolean equals(Object o)
           
 TableColumn getColumn()
          Gives the column on which this table is based.
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

NONE

public static final SortOrder NONE
SortOrder instance indicating the natural order of the data.

Constructor Detail

SortOrder

public SortOrder(TableColumn tcol)
Constructs a new sort order based on a table column.

Parameters:
tcol - table colunmn
Method Detail

getColumn

public TableColumn getColumn()
Gives the column on which this table is based.

Returns:
table column

toString

public String toString()
Overrides:
toString in class Object

equals

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

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2003-2018 CCLRC: Council for the Central Laboratory of the Research Councils. All Rights Reserved.