|
Project Wonder 5.0 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Objecter.javamail.ERMailSender
public class ERMailSender
This class is used to send mails in a threaded way. This is needed in WebObjects because if sending 20 mails takes 40 seconds, then the user must wait 40 seconds before attempting to use the application.
| Nested Class Summary | |
|---|---|
static class |
ERMailSender.SizeOverflowException
Exception class for alerting about a stack overflow |
class |
ERMailSender.Stats
This class is about logging mail event for stats purposes. |
| Field Summary | |
|---|---|
static java.lang.String |
InvalidEmailNotification
|
| Method Summary | |
|---|---|
protected javax.mail.Transport |
_connectedTransportForSession(javax.mail.Session session,
java.lang.String smtpProtocol,
boolean _throwExceptionIfConnectionFails)
Utility method that gets the SMTP Transport method for a session and connects the Transport before returning it. |
protected void |
_sendMessageNow(ERMessage message,
javax.mail.Transport transport)
Common method used by 'sendMessageNow' and 'sendMessageDeffered' (actully the 'run' method when the thread is running) to send a message. |
ERQueue<ERMessage> |
messages()
|
protected void |
notifyInvalidEmails(com.webobjects.foundation.NSArray<java.lang.String> invalidEmails)
Executes the callback method to notify the calling application of any invalid emails. |
void |
run()
Don't call this method, this is the thread run loop and is automatically called. |
void |
sendMessageDeffered(ERMessage message)
Sends a message in a non-blocking way. |
void |
sendMessageNow(ERMessage message)
Sends a message immediately. |
static ERMailSender |
sharedMailSender()
|
ERMailSender.Stats |
stats()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String InvalidEmailNotification
| Method Detail |
|---|
public static ERMailSender sharedMailSender()
public ERMailSender.Stats stats()
public void sendMessageDeffered(ERMessage message)
throws ERMailSender.SizeOverflowException
ERMailSender.SizeOverflowExceptionpublic void sendMessageNow(ERMessage message)
protected void _sendMessageNow(ERMessage message,
javax.mail.Transport transport)
throws javax.mail.MessagingException
javax.mail.MessagingException
protected javax.mail.Transport _connectedTransportForSession(javax.mail.Session session,
java.lang.String smtpProtocol,
boolean _throwExceptionIfConnectionFails)
throws javax.mail.MessagingException
javax.mail.MessagingExceptionpublic void run()
run in interface java.lang.Runnablepublic ERQueue<ERMessage> messages()
protected void notifyInvalidEmails(com.webobjects.foundation.NSArray<java.lang.String> invalidEmails)
|
Last updated: Tue, Feb 21, 2017 05:45 PM CET | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||