Package com.adaptris.util.text.mime
Class SelectByContentId
java.lang.Object
com.adaptris.util.text.mime.SelectByContentId
- All Implemented Interfaces:
PartSelector
PartSelector
implementation that selects by the Content-Id header of the MimeBodyPart.In the adapter configuration file this class is aliased as mime-select-by-content-id which is the preferred alternative to the fully qualified classname when building your configuration.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjavax.mail.internet.MimeBodyPart
Select the body part that should form the AdaptrisMessage payload.List<javax.mail.internet.MimeBodyPart>
select
(javax.mail.internet.MimeMultipart in) Select the body part that should form the AdaptrisMessage payload.void
The Content-Id of the MimeBodyPart to select.
-
Constructor Details
-
SelectByContentId
public SelectByContentId() -
SelectByContentId
-
-
Method Details
-
select
public javax.mail.internet.MimeBodyPart select(BodyPartIterator in) throws javax.mail.MessagingException Description copied from interface:PartSelector
Select the body part that should form the AdaptrisMessage payload.- Specified by:
select
in interfacePartSelector
- Returns:
- the MimeBodyPart that should be the body, or null if no match found.
- Throws:
javax.mail.MessagingException
-
select
public List<javax.mail.internet.MimeBodyPart> select(javax.mail.internet.MimeMultipart in) throws javax.mail.MessagingException Description copied from interface:PartSelector
Select the body part that should form the AdaptrisMessage payload.- Specified by:
select
in interfacePartSelector
- Parameters:
in
- a MimeMultipart- Returns:
- a list of MimeBodyPart that should be the body, empty if no match found.
- Throws:
javax.mail.MessagingException
-
getContentId
- Returns:
- the position
-
setContentId
The Content-Id of the MimeBodyPart to select.- Parameters:
i
- the position to set, count
-