info.monitorenter.util.collections
Class ComparatorToString

java.lang.Object
  extended by info.monitorenter.util.collections.ComparatorToString
All Implemented Interfaces:
Serializable, Comparator

public final class ComparatorToString
extends Object
implements Comparator, Serializable

A Comparator that compares the given Objects by their Object.toString() value.

Version:
$Revision: 1.4 $
Author:
Achim Westermann
See Also:
Serialized Form

Constructor Summary
ComparatorToString()
          Defcon.
 
Method Summary
 int compare(Object o1, Object o2)
          Compares both Objects by their Object.toString() presentation.
 
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

ComparatorToString

public ComparatorToString()
Defcon.

Method Detail

compare

public int compare(Object o1,
                   Object o2)
            throws IllegalArgumentException
Compares both Objects by their Object.toString() presentation.

Specified by:
compare in interface Comparator
Throws:
IllegalArgumentException
See Also:
Comparator.compare(java.lang.Object, java.lang.Object)


Copyright © 2001 - 2007 LGPL, All Rights Footloose.