org.openbp.guiclient.model.item
Class ItemComparator

java.lang.Object
  extended by org.openbp.guiclient.model.item.ItemComparator
All Implemented Interfaces:
java.util.Comparator

public class ItemComparator
extends java.lang.Object
implements java.util.Comparator

Display object comparator. This class is a singleton.

Author:
Heiko Erhardt

Constructor Summary
ItemComparator()
          Private constructor.
 
Method Summary
 int compare(java.lang.Object o1, java.lang.Object o2)
           
 void setItemTypes(java.lang.String[] itemTypes)
          Sets the item types supported by this comparator.
 
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
 

Constructor Detail

ItemComparator

public ItemComparator()
Private constructor.

Method Detail

setItemTypes

public void setItemTypes(java.lang.String[] itemTypes)
Sets the item types supported by this comparator.

Parameters:
itemTypes - The item types in the order they should appear or null if the item type order doesn't matter

compare

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


Copyright © 2011. All Rights Reserved.