Class ComparableOrderMatcher<T>

java.lang.Object
org.hamcrest.BaseMatcher<T>
org.hamcrest.TypeSafeDiagnosingMatcher<Comparator<T>>
org.dmfs.jems2.hamcrest.matchers.comparable.ComparableOrderMatcher<T>
All Implemented Interfaces:
org.hamcrest.Matcher<Comparator<T>>, org.hamcrest.SelfDescribing

public final class ComparableOrderMatcher<T> extends org.hamcrest.TypeSafeDiagnosingMatcher<Comparator<T>>
  • Constructor Summary

    Constructors
    Constructor
    Description
    ComparableOrderMatcher(Iterable<? extends T> orderedValues)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    describeTo(org.hamcrest.Description description)
     
    static <T> org.hamcrest.Matcher<Comparator<T>>
    imposesOrderOf(T... orderedValues)
    Verifies that the Comparator imposes the given strict ordering on the given elements.
    protected boolean
    matchesSafely(Comparator<T> item, org.hamcrest.Description mismatchDescription)
     

    Methods inherited from class org.hamcrest.TypeSafeDiagnosingMatcher

    describeMismatch, matches

    Methods inherited from class org.hamcrest.BaseMatcher

    _dont_implement_Matcher___instead_extend_BaseMatcher_, isNotNull, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • ComparableOrderMatcher

      public ComparableOrderMatcher(Iterable<? extends T> orderedValues)
  • Method Details

    • imposesOrderOf

      @SafeVarargs public static <T> org.hamcrest.Matcher<Comparator<T>> imposesOrderOf(T... orderedValues)
      Verifies that the Comparator imposes the given strict ordering on the given elements.
    • matchesSafely

      protected boolean matchesSafely(Comparator<T> item, org.hamcrest.Description mismatchDescription)
      Specified by:
      matchesSafely in class org.hamcrest.TypeSafeDiagnosingMatcher<Comparator<T>>
    • describeTo

      public void describeTo(org.hamcrest.Description description)