org.opensubsystems.patterns.ordereddata.util
Class OrderedDataComparator

java.lang.Object
  extended by org.opensubsystems.patterns.ordereddata.util.OrderedDataComparator
All Implemented Interfaces:
java.util.Comparator

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

Class for comparing of OrderedData.

Version:
$Id: OrderedDataComparator.java,v 1.3 2007/01/07 06:14:32 bastafidli Exp $
Author:
Peter Satury
Code reviewer:
Miro Halas
Code reviewed:
1.1 2006/04/29 00:25:11 jlegeny

Constructor Summary
OrderedDataComparator()
           
 
Method Summary
 int compare(java.lang.Object o1, java.lang.Object o2)
          
static OrderedDataComparator getInstance()
          Get the default OrderedDataComparator instance.
static void setInstance(OrderedDataComparator defaultInstance)
          Set default OrderedDataComparatory instance.
 
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

OrderedDataComparator

public OrderedDataComparator()
Method Detail

getInstance

public static OrderedDataComparator getInstance()
Get the default OrderedDataComparator instance.

Returns:
default OrderedDataComparator

setInstance

public static void setInstance(OrderedDataComparator defaultInstance)
Set default OrderedDataComparatory instance. This instance will be returned by getInstance method until it is changed.

Parameters:
defaultInstance - - new default OrderedDataComparatory instance

compare

public int compare(java.lang.Object o1,
                   java.lang.Object o2)

Specified by:
compare in interface java.util.Comparator


Copyright © 2003 - 2006 OpenSubsystems s.r.o.