View Javadoc

1   package org.paneris.jammyjoes.mail;
2   
3   import javax.mail.MessagingException;
4   
5   import com.sun.mail.smtp.SMTPTransport;
6   
7   public class TransportAbapter implements MailTransport {
8   
9     private SMTPTransport transport;
10  
11    public TransportAbapter(SMTPTransport transport) {
12      this.transport = transport;
13    }
14  
15    public void send(MimeMail email) throws MessagingException {
16      SMTPTransport.send(email.getMessage());
17    }
18  
19  }