⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mailmessage.html

📁 turbine教程
💻 HTML
📖 第 1 页 / 共 3 页
字号:
</TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setBcc(java.lang.String)">setBcc</A></B>(java.lang.String&nbsp;bc)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being blind-carbon-copied to.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setBody(java.lang.String)">setBody</A></B>(java.lang.String&nbsp;b)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the body of the email message.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setCc(javax.mail.internet.InternetAddress[])">setCc</A></B>(javax.mail.internet.InternetAddress[]&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent to.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setCc(java.lang.String)">setCc</A></B>(java.lang.String&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being carbon-copied to.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setDebug(boolean)">setDebug</A></B>(boolean&nbsp;d)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Setting to true will enable the display of debug information.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setDebug(java.lang.String)">setDebug</A></B>(java.lang.String&nbsp;str)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Setting to true will enable the display of debug information.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setFrom(javax.mail.internet.InternetAddress)">setFrom</A></B>(javax.mail.internet.InternetAddress&nbsp;f)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent from.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setFrom(java.lang.String)">setFrom</A></B>(java.lang.String&nbsp;f)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent from.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setHeaders(java.util.Hashtable)">setHeaders</A></B>(java.util.Hashtable&nbsp;h)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the mail headers.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setHeaders(java.lang.String)">setHeaders</A></B>(java.lang.String&nbsp;h)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the mail headers.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setHost(java.lang.String)">setHost</A></B>(java.lang.String&nbsp;h)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the mail server host.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setReplyTo(javax.mail.internet.InternetAddress[])">setReplyTo</A></B>(javax.mail.internet.InternetAddress[]&nbsp;rt)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent from.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setReplyTo(java.lang.String)">setReplyTo</A></B>(java.lang.String&nbsp;rp)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent from.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setSubject(java.lang.String)">setSubject</A></B>(java.lang.String&nbsp;s)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the subject of the email message.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setTo(javax.mail.internet.InternetAddress[])">setTo</A></B>(javax.mail.internet.InternetAddress[]&nbsp;t)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent to.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../org/apache/turbine/util/mail/MailMessage.html#setTo(java.lang.String)">setTo</A></B>(java.lang.String&nbsp;t)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Used to specify the email address that the mail is being sent to.</TD></TR></TABLE>&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.Object</B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD></TR></TABLE>&nbsp;<P><!-- ============ FIELD DETAIL =========== --><A NAME="field_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Field Detail</B></FONT></TD></TR></TABLE><A NAME="host"><!-- --></A><H3>host</H3><PRE>protected java.lang.String <B>host</B></PRE><DL><DD>The host name of the mail server to use.</DL><HR><A NAME="headers"><!-- --></A><H3>headers</H3><PRE>protected java.util.Hashtable <B>headers</B></PRE><DL><DD>Used to specify the mail headers.  Example: X-Mailer: Sendmail, X-Priority: 1(highest) or  2(high) 3(normal) 4(low) and 5(lowest) Disposition-Notification-To: returnR user@domain.net</DL><HR><A NAME="from"><!-- --></A><H3>from</H3><PRE>protected javax.mail.internet.InternetAddress <B>from</B></PRE><DL><DD>The email address that the mail is being sent from.</DL><HR><A NAME="replyTo"><!-- --></A><H3>replyTo</H3><PRE>protected javax.mail.internet.InternetAddress[] <B>replyTo</B></PRE><DL><DD>The email address used for replies to this message.</DL><HR><A NAME="to"><!-- --></A><H3>to</H3><PRE>protected javax.mail.internet.InternetAddress[] <B>to</B></PRE><DL><DD>The email address or addresses that the email is being sent to.</DL><HR><A NAME="cc"><!-- --></A><H3>cc</H3><PRE>protected javax.mail.internet.InternetAddress[] <B>cc</B></PRE><DL><DD>The email address or addresses that the email is being carbon-copied to.</DL><HR><A NAME="bcc"><!-- --></A><H3>bcc</H3><PRE>protected javax.mail.internet.InternetAddress[] <B>bcc</B></PRE><DL><DD>The email address or addresses that the email is being blind-carbon-copied to.</DL><HR><A NAME="subject"><!-- --></A><H3>subject</H3><PRE>protected java.lang.String <B>subject</B></PRE><DL><DD>The subject of the email message.</DL><HR><A NAME="body"><!-- --></A><H3>body</H3><PRE>protected java.lang.String <B>body</B></PRE><DL><DD>The body of the email message.</DL><HR><A NAME="debug"><!-- --></A><H3>debug</H3><PRE>protected boolean <B>debug</B></PRE><DL><DD>Displays debug information when true.</DL><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="MailMessage()"><!-- --></A><H3>MailMessage</H3><PRE>public <B>MailMessage</B>()</PRE><DL><DD>Default constructor.  Must use the setHost, setTo, and other set functions to properly send an email.  <b>host</b>, <b>to</b>, <b>cc</b>, <b>bcc</b>, and <b>from</b> are set to null.  <b>subject</b>, and <b>body</b> are set to empty strings.  <b>debug</b> is set to false.</DL><HR><A NAME="MailMessage(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String)"><!-- --></A><H3>MailMessage</H3><PRE>public <B>MailMessage</B>(java.lang.String&nbsp;h,                   java.lang.String&nbsp;t,                   java.lang.String&nbsp;f,                   java.lang.String&nbsp;s,                   java.lang.String&nbsp;b)</PRE><DL><DD>Constructor used to specify <b>host</b>, <b>to</b>, <b>from</b>, <b>subject</b>, and <b>body</b>.<DD><DL><DT><B>Parameters:</B><DD><CODE>h</CODE> - A String with the host.<DD><CODE>t</CODE> - A String with the TO.<DD><CODE>f</CODE> - A String with the FROM.<DD><CODE>s</CODE> - A String with the SUBJECT.<DD><CODE>b</CODE> - A String with the BODY.</DL></DD></DL><HR><A NAME="MailMessage(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, boolean)"><!-- --></A><H3>MailMessage</H3><PRE>public <B>MailMessage</B>(java.lang.String&nbsp;h,                   java.lang.String&nbsp;t,                   java.lang.String&nbsp;c,                   java.lang.String&nbsp;bc,                   java.lang.String&nbsp;f,                   java.lang.String&nbsp;s,                   java.lang.String&nbsp;b,                   boolean&nbsp;d)</PRE><DL><DD>Constructor used to specify <b>host</b>, <b>to</b>, <b>cc</b>, <b>bcc</b>, <b>from</b>, <b>subject</b>, <b>body</b>, and <b>debug</b>.<DD><DL><DT><B>Parameters:</B><DD><CODE>h</CODE> - A String with the host.<DD><CODE>t</CODE> - A String with the TO.<DD><CODE>c</CODE> - A String with the CC.<DD><CODE>bc</CODE> - A String with the BCC.<DD><CODE>f</CODE> - A String with the FROM.<DD><CODE>s</CODE> - A String with the SUBJECT.<DD><CODE>b</CODE> - A String with the BODY.<DD><CODE>d</CODE> - True if debugging is wanted.</DL></DD></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="addHeader(java.lang.String, java.lang.String)"><!-- --></A><H3>addHeader</H3><PRE>public void <B>addHeader</B>(java.lang.String&nbsp;name,                      java.lang.String&nbsp;value)</PRE><DL><DD>Adds a header (name, value) to the headers Hashtable.<DD><DL><DT><B>Parameters:</B><DD><CODE>name</CODE> - A String with the name.<DD><CODE>value</CODE> - A String with the value.</DL></DD></DL><HR><A NAME="parseAddressField(java.lang.String)"><!-- --></A><H3>parseAddressField</H3><PRE>public static javax.mail.internet.InternetAddress[] <B>parseAddressField</B>(java.lang.String&nbsp;str)</PRE><DL><DD>Parse an address field.<DD><DL><DT><B>Parameters:</B><DD><CODE>str</CODE> - A String with the address.<DT><B>Returns:</B><DD>An InternetAddress[].</DL></DD></DL>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -