Interface IRefactoringStatusEntryComparator


public interface IRefactoringStatusEntryComparator
Comparator class to compare two refactoring status entries. The general contract of this class is equivalent to the one of class Comparatorfrom the Java Collection Framework.

This interface is intended to be implemented by clients.

Since:
3.1
  • Method Details

    • compare

      int compare(RefactoringStatusEntry entry1, RefactoringStatusEntry entry2)
      Compares two refactoring status entries for order. Returns a negative integer, zero, or a positive integer as the first status entry is less than, equal to, or greater than the second.

      The implementor must ensure that sgn(compare(x, y)) == -sgn(compare(y, x)) for all x and y.

      The implementor must ensure that the relation is transitive: ((compare(x, y)>0) && (compare(y, z)>0)) implies compare(x, z)>0.

      Furthermore, the implementer must ensure that compare(x, y)==0 implies that sgn(compare(x, z))==sgn(compare(y, z)) for all z.

      Parameters:
      entry1 - the first refactoring status entry to be compared.
      entry2 - the second refactoring status entry to be compared.
      Returns:
      a negative integer, zero, or a positive integer as the first status entry is less than, equal to, or greater than the second.