public abstract class MessageContentProcessor extends GenericService
A service which processes the content of an email message in some application-specific way, and stuffs the resulting content into the passed in javax.mail.Message object.
This is an abstract class; the child classes should override
 the setMessageContent method to implement specific 
 content processing schemes.
Message, 
SimpleContentProcessor| Modifier and Type | Class and Description | 
|---|---|
static class  | 
MessageContentProcessor.UrlAndMimeType
Holds the URL and the last mime type of the template. 
 | 
| Modifier and Type | Field and Description | 
|---|---|
static java.lang.String | 
CLASS_VERSION
Class version string 
 | 
SERVICE_INFO_KEYDEFAULT_LOG_TRACE_STATUSDEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS| Constructor and Description | 
|---|
MessageContentProcessor()  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
pruneAlternatives(java.lang.Object pRecipient,
                 java.util.List pUrlAndLastMimeTypeList,
                 boolean pBeforeRender)
Prune the list of alternative types by modifying
 pUrlAndLastMimeTypeList. 
 | 
void | 
setMessageContent(javax.mail.Message pMessage,
                 java.lang.String pContent)
Processes the email message content and stuffs the resulting
 content into the Message. 
 | 
void | 
setMessageContent(javax.mail.Message pMessage,
                 java.lang.String pContent,
                 java.io.File pAttachment,
                 boolean pInlineAttachment)
Processes the email message content and stuffs the resulting
 content into the Message. 
 | 
abstract void | 
setMessageContent(javax.mail.Message pMessage,
                 java.lang.String pContent,
                 java.lang.String pContentType,
                 java.io.File[] pAttachments,
                 boolean pInlineAttachments)
Processes the email message content and stuffs the resulting
 content into the Message. 
 | 
void | 
setMessageContents(javax.mail.Message pMessage,
                  java.lang.String[] pContents,
                  java.lang.String[] pContentTypes,
                  java.io.File[] pAttachments,
                  boolean pInlineAttachments)
Processes the email message content and stuffs the resulting
 content into the Message. 
 | 
boolean | 
supportsMultipleContents()
Whether or not we support multiple contents. 
 | 
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopServicevlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarningpublic void setMessageContent(javax.mail.Message pMessage,
                     java.lang.String pContent)
                       throws TemplateEmailException
TemplateEmailException - if the content could not be 
 processed or set in the Messagepublic void setMessageContent(javax.mail.Message pMessage,
                     java.lang.String pContent,
                     java.io.File pAttachment,
                     boolean pInlineAttachment)
                       throws TemplateEmailException
pAttachment - the file to attach to the message, in 
 addition to setting the regular contentpInlineAttachment - if true, the file will be inlined 
 into the message, rather than attachedTemplateEmailException - if the content could not be 
 processed or set in the Messagepublic abstract void setMessageContent(javax.mail.Message pMessage,
                     java.lang.String pContent,
                     java.lang.String pContentType,
                     java.io.File[] pAttachments,
                     boolean pInlineAttachments)
                                throws TemplateEmailException
pAttachments - the files to attach to the message, in 
 addition to setting the regular contentpInlineAttachments - if true, the files will be inlined 
 into the message, rather than attachedTemplateEmailException - if the content could not be 
 processed or set in the Messagepublic boolean supportsMultipleContents()
public void setMessageContents(javax.mail.Message pMessage,
                      java.lang.String[] pContents,
                      java.lang.String[] pContentTypes,
                      java.io.File[] pAttachments,
                      boolean pInlineAttachments)
                        throws TemplateEmailException
pContents - an array of multi-part-alternative contentspContentTypes - an array of content types which correspond
    to each of the pContents elements.pInlineAttachments - if true, the files will be inlined 
 into the message, rather than attachedpAttachments - the files to attach to the message, in 
 addition to setting the regular contentpInlineAttachments - if true, the files will be inlined 
 into the message, rather than attachedTemplateEmailException - if the content could not be 
 processed or set in the Messagepublic void pruneAlternatives(java.lang.Object pRecipient,
                     java.util.List pUrlAndLastMimeTypeList,
                     boolean pBeforeRender)
pRecipient - The recipient for whole the email
 is being rendered*pUrlAndMimeTypeList - a list of UrlAndMimeType
       objects representing the templates. Note that
       if pBeforeRender is true, the mime-type is calculated
       from the previous time the email template was rendered, and may be
       null.pBeforeRender - whether we are pruning before or after
       the templates have been rendered.