org.apache.james.mailet.standard.matchers
Class SenderHostIs
java.lang.Object
org.apache.mailet.base.GenericMatcher
org.apache.james.mailet.standard.matchers.SenderHostIs
- All Implemented Interfaces:
- Matcher, MatcherConfig
public class SenderHostIs
- extends GenericMatcher
Checkes the sender's displayed domain name against a supplied list.
Sample configuration:
<mailet match="SenderHostIs=domain.com" class="ToProcessor">
<processor> spam </processor>
</mailet>
- Version:
- 1.0.0, 2002-09-10
Method Summary |
void |
init()
Initialize the mailet. |
Collection<MailAddress> |
match(Mail mail)
Takes the message and checks the sender (if there is one) against
the vector of host names. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SenderHostIs
public SenderHostIs()
init
public void init()
- Initialize the mailet.
- Overrides:
init
in class GenericMatcher
match
public Collection<MailAddress> match(Mail mail)
- Takes the message and checks the sender (if there is one) against
the vector of host names.
Returns the collection of recipients if there's a match.
- Specified by:
match
in interface Matcher
- Specified by:
match
in class GenericMatcher
- Parameters:
mail
- the mail being processed
- Returns:
- java.util.Collection - the recipients that the mailet container should have the
mailet affect.
Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.