Пример #1
0
 @Override
 public void diagnoseNotSatisfyingTo(
     Description dissatisfactionDescription, Item<E> item, Description notFoundDescription) {
   if (item.hasAmount()) matcher.describeMismatch(item.get(), dissatisfactionDescription);
   else Describer.concat(dissatisfactionDescription, notFoundDescription);
 }
Пример #2
0
 @Override
 public boolean isSatisfiedBy(Item<E> item) {
   return matcher.matches(item.get());
 }