Package cdc.graphs

Interface PartiallyComparable<T>

Type Parameters:
T - The object type.

public interface PartiallyComparable<T>
Interface implemented by objects that are partially comparable.
Author:
Damien Carbonne
  • Method Details

    • partialCompareTo

      PartialOrderPosition partialCompareTo(T o)
      Return the partial comparison of this object with another one.
      Parameters:
      o - The other object.
      Returns:
      LESS_THAN, EQUAL, GREATER_THAN or UNRELATED if this object is less than, equal to, greater than, or unrelated to o.
      Throws:
      IllegalArgumentException - When o is null.
    • partialCompare

      static <E extends Comparable<? super E>> PartialOrderPosition partialCompare(E left, E right)
      Convert a total order comparison to a partial order comparison.
      Type Parameters:
      E - The Comparable type.
      Parameters:
      left - The left value.
      right - The right value.
      Returns:
      The conversion of left.compareTo(right) into PartialOrderPosition.