org.jboss.seam.mock
public class MockTransport extends javax.mail.Transport
getMailMessage()
returns the most recently rendered
message sent using the MockTransport.
To enable the mock transport, set the mailSession.transport property to mock
in components.properties.Transport
Constructor and Description |
---|
MockTransport(javax.mail.Session session,
javax.mail.URLName urlname) |
Modifier and Type | Method and Description |
---|---|
static void |
clearMailMessage()
Get the most recently rendered message sent using the MockTransport.
|
void |
connect() |
static javax.mail.internet.MimeMessage |
getMailMessage()
Get the most recently rendered message sent using the MockTransport.
|
void |
sendMessage(javax.mail.Message message,
javax.mail.Address[] recipients) |
addTransportListener, notifyTransportListeners, removeTransportListener, send, send
public MockTransport(javax.mail.Session session, javax.mail.URLName urlname)
public void sendMessage(javax.mail.Message message, javax.mail.Address[] recipients) throws javax.mail.MessagingException
sendMessage
in class javax.mail.Transport
javax.mail.MessagingException
public static void clearMailMessage()
public static javax.mail.internet.MimeMessage getMailMessage()
public void connect() throws javax.mail.MessagingException
connect
in class javax.mail.Service
javax.mail.MessagingException
Copyright © 2015 Seam Framework. All Rights Reserved.