com.ctreber.aclib.sort.DefaultComparator Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plantuml Show documentation
Show all versions of plantuml Show documentation
PlantUML is a component that allows to quickly write :
* sequence diagram,
* use case diagram,
* class diagram,
* activity diagram,
* component diagram,
* state diagram
* object diagram
package com.ctreber.aclib.sort;
import java.util.Comparator;
/**
* Implements a default Comparator based on Comparable and a ascending
* sort order. Requires that the two objects are Comparable.
*
* © 2002 Christian Treber, [email protected]
* @author Christian Treber, [email protected]
*
*/
public class DefaultComparator implements Comparator
{
public int compare(Object o1, Object o2)
{
return ((Comparable)o1).compareTo(o2);
}
}