public class TransportStrategyFactory extends Object
Session supports actually 4 types of get transport which are handled by this transport strategy
Session.getTransport() => newSessiontStrategy() Session.getTransport(String) )} => newProtocolStrategy(String) Session.getTransport(URLName) ()} => newUrlNameStrategy(URLName) Session.getTransport(Address) => newUrlNameStrategy(URLName) Session.getTransport(Provider) => newProviderStrategy(Provider) | Constructor and Description |
|---|
TransportStrategyFactory() |
| Modifier and Type | Method and Description |
|---|---|
static TransportStrategy |
newAddressStrategy(javax.mail.Address address) |
static TransportStrategy |
newProtocolStrategy(String protocol) |
static TransportStrategy |
newProviderStrategy(javax.mail.Provider provider) |
static TransportStrategy |
newSessiontStrategy() |
static TransportStrategy |
newUrlNameStrategy(javax.mail.URLName urlName) |
public static TransportStrategy newSessiontStrategy()
public static TransportStrategy newProtocolStrategy(String protocol)
public static TransportStrategy newUrlNameStrategy(javax.mail.URLName urlName)
public static TransportStrategy newAddressStrategy(javax.mail.Address address)
public static TransportStrategy newProviderStrategy(javax.mail.Provider provider)
Copyright © 2016. All rights reserved.