Home » displaytag-1.1.1-src » org » displaytag » model » [javadoc | source]
org.displaytag.model
public class: RowSorter [javadoc | source]
java.lang.Object
   org.displaytag.model.RowSorter

All Implemented Interfaces:
    Comparator

Comparator for rows.
Constructor:
 public RowSorter(int sortedColumnIndex,
    String beanProperty,
    TableDecorator tableDecorator,
    boolean ascendingOrder,
    Comparator compar) 
    Initialize a new RowSorter.
    Parameters:
    sortedColumnIndex - index of the sorted column
    beanProperty - name of the property. If pProperty is null column index is used to get a static cell value from the row object
    tableDecorator - TableDecorator instance
    ascendingOrder - boolean ascending order?
    compar - the comparator to use
Method from org.displaytag.model.RowSorter Summary:
compare,   equals,   hashCode
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.displaytag.model.RowSorter Detail:
 public final int compare(Object object1,
    Object object2) 
    Compares two objects by first fetching a property from each object and then comparing that value. If there are any errors produced while trying to compare these objects then a RunTimeException will be thrown as any error found here will most likely be a programming error that needs to be quickly addressed (like trying to compare objects that are not comparable, or trying to read a property from a bean that is invalid, etc...)
 public final boolean equals(Object object) 
    Is this Comparator the same as another one?
 public final int hashCode()