/** * Check whether the address string specified in the constructor is * a substring of the From address of this Message. * * @param msg The comparison is applied to this Message's From * address. * @return true if the match succeeds, otherwise false. */ public boolean match(Message msg) { Address[] from; try { from = msg.getFrom(); } catch (Exception e) { return false; } if (from == null) return false; for (int i=0; i < from.length; i++) if (super.match(from[i])) return true; return false; }
/** * Equality comparison. */ public boolean equals(Object obj) { if (!(obj instanceof FromStringTerm)) return false; return super.equals(obj); } }
/** * Compute a hashCode for this object. */ public int hashCode() { return type.hashCode() + super.hashCode(); } }
/** * Check whether the address specified in the constructor is * a substring of the recipient address of this Message. * * @param msg The comparison is applied to this Message's recipient * address. * @return true if the match succeeds, otherwise false. */ public boolean match(Message msg) { Address[] recipients; try { recipients = msg.getRecipients(type); } catch (Exception e) { return false; } if (recipients == null) return false; for (int i=0; i < recipients.length; i++) if (super.match(recipients[i])) return true; return false; }
/** * Equality comparison. */ @Override public boolean equals(Object obj) { if (!(obj instanceof FromStringTerm)) return false; return super.equals(obj); } }
/** * Compute a hashCode for this object. */ @Override public int hashCode() { return type.hashCode() + super.hashCode(); } }
/** * Check whether the address string specified in the constructor is * a substring of the From address of this Message. * * @param msg The comparison is applied to this Message's From * address. * @return true if the match succeeds, otherwise false. */ @Override public boolean match(Message msg) { Address[] from; try { from = msg.getFrom(); } catch (Exception e) { return false; } if (from == null) return false; for (int i=0; i < from.length; i++) if (super.match(from[i])) return true; return false; }
/** * Equality comparison. */ @Override public boolean equals(Object obj) { if (!(obj instanceof RecipientStringTerm)) return false; RecipientStringTerm rst = (RecipientStringTerm)obj; return rst.type.equals(this.type) && super.equals(obj); }
/** * Compute a hashCode for this object. */ @Override public int hashCode() { return type.hashCode() + super.hashCode(); } }
/** * Check whether the address specified in the constructor is * a substring of the recipient address of this Message. * * @param msg The comparison is applied to this Message's recipient * address. * @return true if the match succeeds, otherwise false. */ @Override public boolean match(Message msg) { Address[] recipients; try { recipients = msg.getRecipients(type); } catch (Exception e) { return false; } if (recipients == null) return false; for (int i=0; i < recipients.length; i++) if (super.match(recipients[i])) return true; return false; }
/** * Equality comparison. */ public boolean equals(Object obj) { if (!(obj instanceof RecipientStringTerm)) return false; RecipientStringTerm rst = (RecipientStringTerm)obj; return rst.type.equals(this.type) && super.equals(obj); }
/** * Compute a hashCode for this object. */ @Override public int hashCode() { return type.hashCode() + super.hashCode(); } }
/** * Tests if the patterm associated with this Term is a substring of * the address in the supplied object. * * @param address * @return */ protected boolean match(Address address) { return match(address.toString()); } }
/** * Equality comparison. */ @Override public boolean equals(Object obj) { if (!(obj instanceof FromStringTerm)) return false; return super.equals(obj); } }
/** * Compute a hashCode for this object. */ public int hashCode() { return type.hashCode() + super.hashCode(); } }
/** * Tests if the patterm associated with this Term is a substring of * the address in the supplied object. * * @param address * @return */ protected boolean match(Address address) { return match(address.toString()); } }
/** * Equality comparison. */ public boolean equals(Object obj) { if (!(obj instanceof FromStringTerm)) return false; return super.equals(obj); } }
/** * Compute a hashCode for this object. */ @Override public int hashCode() { return type.hashCode() + super.hashCode(); } }
/** * Check whether the address string specified in the constructor is * a substring of the From address of this Message. * * @param msg The comparison is applied to this Message's From * address. * @return true if the match succeeds, otherwise false. */ @Override public boolean match(Message msg) { Address[] from; try { from = msg.getFrom(); } catch (Exception e) { return false; } if (from == null) return false; for (int i=0; i < from.length; i++) if (super.match(from[i])) return true; return false; }
/** * Equality comparison. */ @Override public boolean equals(Object obj) { if (!(obj instanceof FromStringTerm)) return false; return super.equals(obj); } }