Package com.jalios.jcms.mail.listener
Class IncomingMailFetching
- java.lang.Object
-
- com.jalios.jcms.mail.listener.IncomingMailFetching
-
public class IncomingMailFetching extends java.lang.Object
A fetching process of theIncomingMailListener
.Processes fetching Criterias (see
AbstractIncomingMailFetchCriteria
).- Since:
- jcms-9.0.0
- Version:
- $Revision: 112713 $
- Author:
- Sylvain Devaux
-
-
Field Summary
Fields Modifier and Type Field Description protected IncomingMailListener.IncomingMailCriteria
criteria
A copy of the Criteria.protected static java.lang.Class<? extends FetchCriteria>[]
criteriaClasses
Ordered criteria class to process.protected MailMessage
mail
The Mail being processed.protected java.util.regex.Pattern
pattern
The Pattern being processed.static java.lang.String
REVISION
-
Constructor Summary
Constructors Constructor Description IncomingMailFetching(java.util.regex.Pattern pattern, MailMessage mail, IncomingMailListener.IncomingMailCriteria criteria)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IncomingMailListener.IncomingMailCriteria
getCriteria()
MailMessage
getMail()
java.lang.String
getMatchingRecipient()
boolean
isMatchingRecipient()
boolean
processCriterias()
java.lang.String
toString()
-
-
-
Field Detail
-
REVISION
public static final java.lang.String REVISION
- See Also:
- Constant Field Values
-
pattern
protected java.util.regex.Pattern pattern
The Pattern being processed.
-
mail
protected MailMessage mail
The Mail being processed.
-
criteria
protected IncomingMailListener.IncomingMailCriteria criteria
A copy of the Criteria. Its fields may be overrided.
-
criteriaClasses
protected static java.lang.Class<? extends FetchCriteria>[] criteriaClasses
Ordered criteria class to process.
-
-
Constructor Detail
-
IncomingMailFetching
public IncomingMailFetching(java.util.regex.Pattern pattern, MailMessage mail, IncomingMailListener.IncomingMailCriteria criteria)
-
-
Method Detail
-
processCriterias
public boolean processCriterias()
- Returns:
- true if some Criteria validate the current Mail, and the mail
should be fetched. See
AbstractIncomingMailFetchCriteria
. - Since:
- jcms-9.0.0
-
isMatchingRecipient
public boolean isMatchingRecipient()
-
getCriteria
public IncomingMailListener.IncomingMailCriteria getCriteria()
- Returns:
- a copy of the initial criteria. This copy is used to override Criteria fields.
- Since:
- jcms-9.0.0
-
getMail
public MailMessage getMail()
- Returns:
- the mail
- Since:
- jcms-9.0.0
-
getMatchingRecipient
public java.lang.String getMatchingRecipient()
- Returns:
- an optional Mail's recipient that matches the Pattern.
- Since:
- jcms-9.0.0
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-