|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.geronimo.mail.MailGBean
public class MailGBean
GBean that provides access to JavaMail Sessions.
This GBean is used to generate JavaMail Sessions. JavaMail properties that are common to all JavaMail Sessions are provided via member variables of this class.
ProtocolGBean
,
SMTPTransportGBean
,
POP3StoreGBean
,
IMAPStoreGBean
Field Summary | |
---|---|
static org.apache.geronimo.gbean.GBeanInfo |
GBEAN_INFO
|
Constructor Summary | |
---|---|
MailGBean(String objectName,
Collection protocols,
Boolean useDefault,
Properties properties,
Authenticator authenticator,
String storeProtocol,
String transportProtocol,
String host,
String user,
Boolean debug)
Construct an instance of MailGBean Values that are set in the individual member variables will override any of the corresponding values that have been set in the properties set. |
Method Summary | |
---|---|
Object |
$getResource()
|
void |
doFail()
|
void |
doStart()
|
void |
doStop()
|
Authenticator |
getAuthenticator()
Returns the authenticator object. |
Boolean |
getDebug()
Returns the debug setting for Sessions created from this GBean. |
static org.apache.geronimo.gbean.GBeanInfo |
getGBeanInfo()
|
String |
getHost()
Returns the default Mail server. |
String |
getObjectName()
Returns the GBean name of this Mail GBean |
Properties |
getProperties()
Returns the set of default properties for the protocols. |
Collection |
getProtocols()
Returns the set of protocol GBeans that contain protocol specific configurations. |
String |
getStoreProtocol()
Returns the store protocol that Sessions created from this GBean will return. |
String |
getTransportProtocol()
Returns the transport protocol that Sessions created from this GBean will return. |
Boolean |
getUseDefault()
Returns whether this GBean will return default Sessions or not. |
String |
getUser()
Returns the username to provide when connecting to a Mail server. |
boolean |
isEventProvider()
|
boolean |
isStateManageable()
|
boolean |
isStatisticsProvider()
|
void |
setAuthenticator(Authenticator authenticator)
Sets the authenticator object. |
void |
setDebug(Boolean debug)
Sets the debug setting for Sessions created from this GBean. |
void |
setHost(String host)
Sets the default Mail server. |
void |
setProperties(Properties properties)
Sets the set of default properties for the protocols. |
void |
setStoreProtocol(String storeProtocol)
Sets the store protocol that Sessions created from this GBean will return. |
void |
setTransportProtocol(String transportProtocol)
Sets the transport protocol that Sessions created from this GBean will return. |
void |
setUseDefault(Boolean useDefault)
Sets whether this GBean will return default Sessions or not, |
void |
setUser(String user)
Sets the username to provide when connecting to a Mail server. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final org.apache.geronimo.gbean.GBeanInfo GBEAN_INFO
Constructor Detail |
---|
public MailGBean(String objectName, Collection protocols, Boolean useDefault, Properties properties, Authenticator authenticator, String storeProtocol, String transportProtocol, String host, String user, Boolean debug)
Values that are set in the individual member variables will override any of the corresponding values that have been set in the properties set.
protocols
- the set of protocol GBeans that contain protocol specific configurationsuseDefault
- whether this GBean will return default Sessions or notproperties
- the set of default properties for the protocolsauthenticator
- the authenticator objectstoreProtocol
- the store protocol that Sessions created from this GBean will returntransportProtocol
- the transport protocol that Sessions created from this GBean will returnhost
- the default Mail serveruser
- the username to provide when connecting to a Mail serverdebug
- the debug setting for Sessions created from this GBeanMethod Detail |
---|
public Collection getProtocols()
public Boolean getUseDefault()
public void setUseDefault(Boolean useDefault)
useDefault
- whether this GBean will return default Sessions or notpublic Properties getProperties()
Note: Proerties that are set here will override the properties that are set in the protocol GBeans.
public void setProperties(Properties properties)
Note: Proerties that are set here will override the properties that are set in the protocol GBeans.
properties
- the set of default properties for the protocolspublic Authenticator getAuthenticator()
Used only if a new Session object is created. Otherwise, it must match the Authenticator used to create the Session.
public void setAuthenticator(Authenticator authenticator)
Used only if a new Session object is created. Otherwise, it must match the Authenticator used to create the Session.
authenticator
- the authenticator objectpublic String getStoreProtocol()
Specifies the default Message Access Protocol. The Session.getStore() method returns a Store object that implements this protocol. The client can override this property and explicitly specify the protocol with the Session.getStore(String protocol) method.
public void setStoreProtocol(String storeProtocol)
Specifies the default Message Access Protocol. The Session.getStore() method returns a Store object that implements this protocol. The client can override this property and explicitly specify the protocol with the Session.getStore(String protocol) method.
Values that are set here will override any of the corresponding value that has been set in the properties.
storeProtocol
- the store protocol that Sessions created from this GBean will returnpublic String getTransportProtocol()
Specifies the default Transport Protocol. The Session.getTransport() method returns a Transport object that implements this protocol. The client can override this property and explicitly specify the protocol by using Session.getTransport(String protocol) method.
public void setTransportProtocol(String transportProtocol)
Specifies the default Transport Protocol. The Session.getTransport() method returns a Transport object that implements this protocol. The client can override this property and explicitly specify the protocol by using Session.getTransport(String protocol) method.
Values that are set here will override any of the corresponding value that has been set in the properties.
transportProtocol
- the transport protocol that Sessions created from this GBean will returnpublic String getHost()
Specifies the default Mail server. The Store and Transport object’s connect methods use this property, if the protocolspecific host property is absent, to locate the target host.
public void setHost(String host)
Specifies the default Mail server. The Store and Transport object’s connect methods use this property, if the protocolspecific host property is absent, to locate the target host.
Values that are set here will override any of the corresponding value that has been set in the properties.
host
- the default Mail serverpublic String getUser()
Specifies the username to provide when connecting to a Mail server. The Store and Transport object’s connect methods use this property, if the protocolspecific username property is absent, to obtain the username.
public void setUser(String user)
Specifies the username to provide when connecting to a Mail server. The Store and Transport object’s connect methods use this property, if the protocolspecific username property is absent, to obtain the username.
Values that are set here will override any of the corresponding value that has been set in the properties.
user
- the username to provide when connecting to a Mail serverpublic Boolean getDebug()
public void setDebug(Boolean debug)
Values that are set here will override any of the corresponding value that has been set in the properties.
debug
- the debug setting for Sessions created from this GBeanpublic Object $getResource()
public void doStart() throws Exception
doStart
in interface org.apache.geronimo.gbean.GBeanLifecycle
Exception
public void doStop() throws Exception
doStop
in interface org.apache.geronimo.gbean.GBeanLifecycle
Exception
public void doFail()
doFail
in interface org.apache.geronimo.gbean.GBeanLifecycle
public String getObjectName()
getObjectName
in interface org.apache.geronimo.management.J2EEManagedObject
public boolean isStateManageable()
isStateManageable
in interface org.apache.geronimo.management.J2EEManagedObject
public boolean isStatisticsProvider()
isStatisticsProvider
in interface org.apache.geronimo.management.J2EEManagedObject
public boolean isEventProvider()
isEventProvider
in interface org.apache.geronimo.management.J2EEManagedObject
public static org.apache.geronimo.gbean.GBeanInfo getGBeanInfo()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |