|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.clapper.util.mail.SMTPEmailTransport
public class SMTPEmailTransport
SMTPEmailTransport defines a class that sends EmailMessage objects via the Simple Mail Transfer Protocol (SMTP). You instantiate an SMTPEmailTransport object by specifying the SMTP host to be used to send messages, and you then use the object to send EmailMessage objects.
EmailMessage| Constructor Summary | |
|---|---|
SMTPEmailTransport()
Constructs a new SMTPEmailTransport object that will use the local host as its SMTP server. |
|
SMTPEmailTransport(java.lang.String smtpHost)
Constructs a new SMTPEmailTransport object, with the specified SMTP host. |
|
| Method Summary | |
|---|---|
void |
send(EmailMessage message)
Attempts to deliver the message via the specified SMTP host. |
void |
setDebug(boolean debug,
java.io.PrintStream out)
Enable or disable the underlying implementation's debug flag, if there is one. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SMTPEmailTransport()
throws EmailException
EmailException - unable to initialize
public SMTPEmailTransport(java.lang.String smtpHost)
throws EmailException
smtpHost - The SMTP host to use to send messages
EmailException - unable to initializesend(EmailMessage)| Method Detail |
|---|
public void setDebug(boolean debug,
java.io.PrintStream out)
setDebug in interface EmailTransportdebug - true to enable debug, false to
disable itout - where to dump debug messages, or null for standard
output. Ignored unless debug is true.
public void send(EmailMessage message)
throws EmailException
send in interface EmailTransportmessage - the message to send
EmailException - Failed to send the message.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||