Class SameTypePairComparator<T>

    • Constructor Detail

      • SameTypePairComparator

        public SameTypePairComparator​(TypeComparator<T> comp)
    • Method Detail

      • setReference

        public void setReference​(T reference)
        Description copied from class: TypePairComparator
        Sets the reference for comparisons.
        Specified by:
        setReference in class TypePairComparator<T,​T>
        Parameters:
        reference - The reference instance.
      • equalToReference

        public boolean equalToReference​(T candidate)
        Description copied from class: TypePairComparator
        Checks, whether the given candidate instance is equal to the reference instance, with respect to this comparator's equality definition.
        Specified by:
        equalToReference in class TypePairComparator<T,​T>
        Parameters:
        candidate - The candidate to check.
        Returns:
        True, if the candidate is equal to the reference, false otherwise.