JClass DesktopViews 6.3.0 API
Documentation

com.klg.jclass.higrid
Class DefaultSortable

java.lang.Object
  |
  +--com.klg.jclass.higrid.DefaultSortable
All Implemented Interfaces:
Comparator, Serializable

public class DefaultSortable
extends Object
implements Serializable, Comparator

DefaultSortable is the default HiGrid implementation of the Comparator interface. It sorts all items based on their data type. Any unrecognized types are sorted based on their toString() value.

Since:
JClass 4.0K for Java 2. If you are using JClass 4.0J, which is based on JDK 1.1, the Comparator implementation is based on com.sun.java.util.collections.Comparator.
See Also:
Serialized Form

Field Summary
static int EQUAL
           
static int GREATER_THAN
           
static int LESS_THAN
           
 
Constructor Summary
DefaultSortable()
           
 
Method Summary
 int compare(Object a, Object b)
          Compares its two arguments for order.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Field Detail

LESS_THAN

public static final int LESS_THAN
See Also:
Constant Field Values

EQUAL

public static final int EQUAL
See Also:
Constant Field Values

GREATER_THAN

public static final int GREATER_THAN
See Also:
Constant Field Values
Constructor Detail

DefaultSortable

public DefaultSortable()
Method Detail

compare

public int compare(Object a,
                   Object b)
Compares its two arguments for order.

Specified by:
compare in interface Comparator
Returns:
a negative integer, zero, or a positive integer as the first argument is less than, equal to, or greater than the second.

Copyright © 2004 Quest Software Inc..
All rights reserved.