public class CmsWorkflowNotification extends A_CmsNotification
m_mailContent
ATTACHMENTS, authenticator, bccList, bounceAddress, ccList, charset, content, CONTENT_TYPE, contentType, debug, EMAIL_BODY, EMAIL_SUBJECT, emailBody, FILE_SERVER, fromAddress, headers, hostName, ISO_8859_1, KOI8_R, MAIL_DEBUG, MAIL_HOST, MAIL_PORT, MAIL_SMTP_AUTH, MAIL_SMTP_CONNECTIONTIMEOUT, MAIL_SMTP_FROM, MAIL_SMTP_PASSWORD, MAIL_SMTP_SOCKET_FACTORY_CLASS, MAIL_SMTP_SOCKET_FACTORY_FALLBACK, MAIL_SMTP_SOCKET_FACTORY_PORT, MAIL_SMTP_TIMEOUT, MAIL_SMTP_USER, MAIL_TRANSPORT_PROTOCOL, MAIL_TRANSPORT_TLS, message, popBeforeSmtp, popHost, popPassword, popUsername, RECEIVER_EMAIL, RECEIVER_NAME, replyList, SENDER_EMAIL, SENDER_NAME, sentDate, SMTP, smtpPort, socketConnectionTimeout, socketTimeout, ssl, sslSmtpPort, subject, TEXT_HTML, TEXT_PLAIN, tls, toList, US_ASCII
构造器和说明 |
---|
CmsWorkflowNotification(CmsObject adminCms,
CmsObject userCms,
CmsUser receiver,
java.lang.String notificationContent,
CmsProject project,
java.util.List<CmsResource> resources,
java.lang.String link)
Creates a new workflow notification mail object.
|
限定符和类型 | 方法和说明 |
---|---|
protected java.lang.String |
generateHtmlMsg()
Overwrite the method to generate the message body of the notification.
|
protected java.lang.String |
getMessage(java.lang.String key,
java.lang.String... args)
Gets a message from the message bundle.
|
protected java.lang.String |
getNotificationContent()
Overwrite the method to return the path to the xmlcontent, where the subject,
the header and the footer are defined.
|
java.lang.String[] |
getResourceInfo(CmsResource resource)
Gets the fields which should be displayed for a single resource.
|
java.lang.String[] |
getResourceInfoHeaders()
Gets the resource info headers.
|
addMacro, appendHtmlHeader, appenHtmlFooter, getCmsObject, getLocale, getReceiver, send
buildMimeMessage, embed, embed, embed, embed, embed, embed, setHtmlMsg, setMsg, setTextMsg
addPart, addPart, addPart, attach, attach, attach, attach, attach, createBodyPart, createMimeMultipart, getContainer, getPrimaryBodyPart, getSubType, init, isBoolHasAttachments, isInitialized, setBoolHasAttachments, setInitialized, setSubType
addBcc, addBcc, addBcc, addCc, addCc, addCc, addHeader, addReplyTo, addReplyTo, addReplyTo, addTo, addTo, addTo, createMimeMessage, getBccAddresses, getCcAddresses, getFromAddress, getHostName, getMailSession, getMimeMessage, getReplyToAddresses, getSentDate, getSmtpPort, getSocketConnectionTimeout, getSocketTimeout, getSslSmtpPort, getSubject, getToAddresses, isSSL, isTLS, sendMimeMessage, setAuthentication, setAuthenticator, setBcc, setBounceAddress, setCc, setCharset, setContent, setContent, setDebug, setFrom, setFrom, setFrom, setHeaders, setHostName, setMailSession, setMailSessionFromJNDI, setPopBeforeSmtp, setReplyTo, setSentDate, setSmtpPort, setSocketConnectionTimeout, setSocketTimeout, setSSL, setSslSmtpPort, setSubject, setTLS, setTo, toInternetAddressArray, updateContentType
public CmsWorkflowNotification(CmsObject adminCms, CmsObject userCms, CmsUser receiver, java.lang.String notificationContent, CmsProject project, java.util.List<CmsResource> resources, java.lang.String link) throws org.apache.commons.mail.EmailException
adminCms
- the admin CMS contextuserCms
- the user CMS contextreceiver
- the mail recipientnotificationContent
- the file from which to read the notification configurationproject
- the workflow projectresources
- the workflow resourceslink
- the link used for publishing the resourcesorg.apache.commons.mail.EmailException
- if an email error occurspublic java.lang.String[] getResourceInfo(CmsResource resource)
resource
- the resource for which we should fetch the fieldspublic java.lang.String[] getResourceInfoHeaders()
protected java.lang.String generateHtmlMsg()
A_CmsNotification
generateHtmlMsg
在类中 A_CmsNotification
A_CmsNotification.generateHtmlMsg()
protected java.lang.String getMessage(java.lang.String key, java.lang.String... args)
key
- the message keyargs
- the message parametersprotected java.lang.String getNotificationContent()
A_CmsNotification
getNotificationContent
在类中 A_CmsNotification
A_CmsNotification.getNotificationContent()