| java.lang.Object vqwiki.WikiMail
WikiMail | public class WikiMail (Code) | | Sends mail via SMTP to the specified host. REDISTRIBUTION: you
will either have to hard-code your own SMTP host name into the constructor
function and recompile, or rewrite the Environment class to record
this information in the vqwiki.properties file.
author: Robert E Brewer version: 0.1 |
Constructor Summary | |
public | WikiMail() Construct the object by opening a JavaMail session. |
WikiMail | public WikiMail()(Code) | | Construct the object by opening a JavaMail session. Use getInstance to provide Singleton behavior.
|
getInstance | public static WikiMail getInstance()(Code) | | Provide a Singleton instance of the object.
|
init | public static void init()(Code) | | |
sendMail | public void sendMail(String from, String to, String subject, String body)(Code) | | Send mail via SMTP. MessagingExceptions are silently dropped.
Parameters: from - the RFC 821 "MAIL FROM" parameter Parameters: to - the RFC 821 "RCPT TO" parameter Parameters: subject - the RFC 822 "Subject" field Parameters: body - the RFC 822 "Body" field |
|
|