|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.mail.SimpleMailMessage
public class SimpleMailMessage
Models a simple mail message, including data such as the from, to, cc, subject, and text fields.
Consider JavaMailSender
and JavaMail MimeMessages
for creating
more sophisticated messages, for example messages with attachments, special
character encodings, or personal names that accompany mail addresses.
MailSender
,
JavaMailSender
,
MimeMessagePreparator
,
MimeMessageHelper
,
MimeMailMessage
,
Serialized FormConstructor Summary | |
---|---|
SimpleMailMessage()
Create a new SimpleMailMessage . |
|
SimpleMailMessage(SimpleMailMessage original)
Copy constructor for creating a new SimpleMailMessage from the state
of an existing SimpleMailMessage instance. |
Method Summary | |
---|---|
void |
copyTo(MailMessage target)
Copy the contents of this message to the given target message. |
boolean |
equals(Object other)
|
String[] |
getBcc()
|
String[] |
getCc()
|
String |
getFrom()
|
String |
getReplyTo()
|
Date |
getSentDate()
|
String |
getSubject()
|
String |
getText()
|
String[] |
getTo()
|
int |
hashCode()
|
void |
setBcc(String bcc)
|
void |
setBcc(String[] bcc)
|
void |
setCc(String cc)
|
void |
setCc(String[] cc)
|
void |
setFrom(String from)
|
void |
setReplyTo(String replyTo)
|
void |
setSentDate(Date sentDate)
|
void |
setSubject(String subject)
|
void |
setText(String text)
|
void |
setTo(String to)
|
void |
setTo(String[] to)
|
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public SimpleMailMessage()
SimpleMailMessage
.
public SimpleMailMessage(SimpleMailMessage original)
SimpleMailMessage
from the state
of an existing SimpleMailMessage
instance.
IllegalArgumentException
- if the supplied message is null
Method Detail |
---|
public void setFrom(String from)
setFrom
in interface MailMessage
public String getFrom()
public void setReplyTo(String replyTo)
setReplyTo
in interface MailMessage
public String getReplyTo()
public void setTo(String to)
setTo
in interface MailMessage
public void setTo(String[] to)
setTo
in interface MailMessage
public String[] getTo()
public void setCc(String cc)
setCc
in interface MailMessage
public void setCc(String[] cc)
setCc
in interface MailMessage
public String[] getCc()
public void setBcc(String bcc)
setBcc
in interface MailMessage
public void setBcc(String[] bcc)
setBcc
in interface MailMessage
public String[] getBcc()
public void setSentDate(Date sentDate)
setSentDate
in interface MailMessage
public Date getSentDate()
public void setSubject(String subject)
setSubject
in interface MailMessage
public String getSubject()
public void setText(String text)
setText
in interface MailMessage
public String getText()
public void copyTo(MailMessage target)
target
- the MailMessage
to copy to
IllegalArgumentException
- if the supplied target
is null
public String toString()
public boolean equals(Object other)
public int hashCode()
|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |