com.atlassian.crowd.upgrade.util
Class BuildNumberComparator

java.lang.Object
  extended by com.atlassian.crowd.upgrade.util.BuildNumberComparator
All Implemented Interfaces:
java.util.Comparator

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

A comparator for Crowd build numbers.


Constructor Summary
BuildNumberComparator()
           
 
Method Summary
 int compare(java.lang.Object o1, java.lang.Object o2)
          Compares two string representation of build numbers.
 
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

BuildNumberComparator

public BuildNumberComparator()
Method Detail

compare

public int compare(java.lang.Object o1,
                   java.lang.Object o2)
Compares two string representation of build numbers.

These strings must be parsable to a number.

Specified by:
compare in interface java.util.Comparator
Parameters:
o1 -
o2 -
Returns:
Underlying number comparison notation - 1 = greater than, 0 = equals, -1 = less than.


Copyright © 2010 Atlassian. All Rights Reserved.