@Test public void shouldNotBeEqualIfOtherIsNotANotPredicate() throws Exception { Predicate<Object> first = not(alwaysTrue()); Predicate<Object> second = alwaysFalse(); boolean equal = first.equals(second); assertThat(equal, is(false)); }
@Override public boolean equals(Object other) { return EqualsBuilder.reflectionEquals(this, other); }
NotPredicate implements Predicate<T> { @Override public boolean equals(Object other) { return EqualsBuilder.reflectionEquals(this, other); } }
NotPredicate implements Predicate<T> { @Override public boolean equals(Object other) { return EqualsBuilder.reflectionEquals(this, other); } NotPredicate(UnaryPredicate<? super T> predicate); }
NotPredicate implements Predicate<T> { @Override public boolean equals(Object other) { return EqualsBuilder.reflectionEquals(this, other); } NotPredicate(UnaryPredicate<? super T> predicate); @Override boolean evaluate(T instance); @Override boolean equals(Object other); @Override int hashCode(); }
NotPredicate implements Predicate<T> { @Override public boolean equals(Object other) { return EqualsBuilder.reflectionEquals(this, other); } NotPredicate(UnaryPredicate<? super T> predicate); @Override boolean evaluate(T instance); @Override boolean equals(Object other); @Override int hashCode();  }