org.apache.velocity.tools.generic
Class SortTool.PropertiesComparator

java.lang.Object
  extended by org.apache.velocity.tools.generic.SortTool.PropertiesComparator
All Implemented Interfaces:
java.io.Serializable, java.util.Comparator
Enclosing class:
SortTool

public static class SortTool.PropertiesComparator
extends java.lang.Object
implements java.util.Comparator, java.io.Serializable

Does all of the comparisons

See Also:
Serialized Form

Field Summary
(package private)  java.util.List properties
           
(package private)  int[] sortTypes
           
private static int TYPE_ASCENDING
           
static java.lang.String TYPE_ASCENDING_SHORT
           
private static int TYPE_DESCENDING
           
static java.lang.String TYPE_DESCENDING_SHORT
           
 
Constructor Summary
SortTool.PropertiesComparator(java.util.List props)
           
 
Method Summary
 int compare(java.lang.Object lhs, java.lang.Object rhs)
           
 
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

TYPE_ASCENDING

private static final int TYPE_ASCENDING
See Also:
Constant Field Values

TYPE_DESCENDING

private static final int TYPE_DESCENDING
See Also:
Constant Field Values

TYPE_ASCENDING_SHORT

public static final java.lang.String TYPE_ASCENDING_SHORT
See Also:
Constant Field Values

TYPE_DESCENDING_SHORT

public static final java.lang.String TYPE_DESCENDING_SHORT
See Also:
Constant Field Values

properties

java.util.List properties

sortTypes

int[] sortTypes
Constructor Detail

SortTool.PropertiesComparator

public SortTool.PropertiesComparator(java.util.List props)
Method Detail

compare

public int compare(java.lang.Object lhs,
                   java.lang.Object rhs)
Specified by:
compare in interface java.util.Comparator


Copyright (c) 2003-2007 Apache Software Foundation