com.extjs.gxt.ui.client.store
Class StoreSorter<M extends ModelData>

java.lang.Object
  extended by com.extjs.gxt.ui.client.store.StoreSorter<M>
Type Parameters:
M - the record type

public class StoreSorter<M extends ModelData>
extends java.lang.Object

Sorts the records in a store.


Field Summary
protected  java.util.Comparator<java.lang.Object> comparator
           
static DefaultComparator<java.lang.Object> DEFAULT_COMPARATOR
          The default comparator instance.
 
Constructor Summary
StoreSorter()
          Creates a new store sorter.
StoreSorter(java.util.Comparator<java.lang.Object> comparator)
          Creates a new store sorter.
 
Method Summary
 int compare(Store<M> store, M m1, M m2, java.lang.String property)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_COMPARATOR

public static DefaultComparator<java.lang.Object> DEFAULT_COMPARATOR
The default comparator instance.


comparator

protected java.util.Comparator<java.lang.Object> comparator
Constructor Detail

StoreSorter

public StoreSorter()
Creates a new store sorter.


StoreSorter

public StoreSorter(java.util.Comparator<java.lang.Object> comparator)
Creates a new store sorter.

Parameters:
comparator - the comparator
Method Detail

compare

public int compare(Store<M> store,
                   M m1,
                   M m2,
                   java.lang.String property)