Class DistinctFrom<T>

  • All Implemented Interfaces:
    org.hamcrest.Matcher<java.util.Set<T>>, org.hamcrest.SelfDescribing

    public class DistinctFrom<T>
    extends org.hamcrest.BaseMatcher<java.util.Set<T>>
    Matcher to check that two sets does not have any common elements. The elements must have proper equals method implementations for this matcher to work.
    • Constructor Summary

      Constructors 
      Constructor Description
      DistinctFrom​(java.util.Set<T> from)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void describeMismatch​(java.lang.Object o, org.hamcrest.Description description)  
      void describeTo​(org.hamcrest.Description description)  
      boolean matches​(java.lang.Object o)  
      • Methods inherited from class org.hamcrest.BaseMatcher

        _dont_implement_Matcher___instead_extend_BaseMatcher_, toString
      • Methods inherited from class java.lang.Object

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

      • DistinctFrom

        public DistinctFrom​(java.util.Set<T> from)
    • Method Detail

      • matches

        public boolean matches​(java.lang.Object o)
      • describeMismatch

        public void describeMismatch​(java.lang.Object o,
                                     org.hamcrest.Description description)
        Specified by:
        describeMismatch in interface org.hamcrest.Matcher<T>
        Overrides:
        describeMismatch in class org.hamcrest.BaseMatcher<java.util.Set<T>>
      • describeTo

        public void describeTo​(org.hamcrest.Description description)