Name

Transport

Synopsis

An abstract class modeling a message transport service, such as SMTP. Basic service related methods are provided via the parent Service class.

                  
public abstract class Transport extends Service {
// Public Constructors
   public Transport(javax.mail.Session session, 
        URLName urlname);  
// Public Class Methods
   public static void send(
        javax.mail.Message msg) throws MessagingException;  
   public static void send(javax.mail.Message msg, 
        Address[] addresses) throws MessagingException;  
// Event Registration Methods (by event name)
   public void addTransportListener(                             // synchronized
        javax.mail.event.TransportListener l);  
   public void removeTransportListener(                          // synchronized
        javax.mail.event.TransportListener l);  
// Public Instance Methods
   public abstract void sendMessage(javax.mail.Message msg, 
        Address[] addresses) throws MessagingException;  
// Protected Instance Methods
   protected void notifyTransportListeners(int type, 
        Address[] validSent, 
        Address[] validUnsent, 
        Address[] invalid, 
        javax.mail.Message msg);  
}

Passed To

javax.mail.event.TransportEvent.TransportEvent()

Returned By

javax.mail.Session.getTransport()

Get Java Enterprise in a Nutshell, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.