org.mmbase.module.core
Class MMContainerCompare
java.lang.Object
org.mmbase.module.core.MMContainerCompare
- All Implemented Interfaces:
- CompareInterface
- public class MMContainerCompare
- extends Object
- implements CompareInterface
Class to compare two MMObjectNodes, used by SortedVector.
- Version:
- $Id: MMContainerCompare.java,v 1.7 2005/05/14 14:04:45 nico Exp $
- Author:
- Rico Jansen
- See Also:
SortedVector,
CompareInterface- To Do:
- Should implement java.util.Comparator. Perhaps should be named MMObjectNodeComparator. Btw, this class is not used.
|
Field Summary |
static boolean |
ASC
|
static boolean |
DESC
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ASC
public static final boolean ASC
- See Also:
- Constant Field Values
DESC
public static final boolean DESC
- See Also:
- Constant Field Values
MMContainerCompare
public MMContainerCompare()
MMContainerCompare
public MMContainerCompare(Vector orderfields)
MMContainerCompare
public MMContainerCompare(Vector orderfields,
Vector orderdirections)
setCompare
public void setCompare(String field,
CompareInterface handler)
addField
public void addField(String field)
addField
public void addField(String field,
boolean direction)
setField
public boolean setField(String field,
boolean direction)
setOrderFields
public void setOrderFields(Vector orderfields)
setOrderDirections
public void setOrderDirections(Vector orderdirections)
setOrder
public void setOrder(Vector orderfields,
Vector orderdirections)
compare
public int compare(Object thisone,
Object other)
- The compare function called by SortedVector to sort things.
- Specified by:
compare in interface CompareInterface
- See Also:
SortedVector,
CompareInterface
MMBase build 1.8.1.20060716