class IsSingleRecipient extends GenericMatcher {

    @Override
    public Collection<MailAddress> match(Mail mail) {
        if (mail.getRecipients().size() == 1) {
            return mail.getRecipients();
        } else {
            return null;
        }
    }

}