geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jlaskow...@apache.org
Subject svn commit: r387533 [1/2] - in /geronimo/trunk/modules/mail/src: java/org/apache/geronimo/mail/ test/org/apache/geronimo/mail/
Date Tue, 21 Mar 2006 14:14:17 GMT
Author: jlaskowski
Date: Tue Mar 21 06:14:15 2006
New Revision: 387533

URL: http://svn.apache.org/viewcvs?rev=387533&view=rev
Log:
GERONIMO-1754 - Add GBeans for configuring NNTPTransport and NNTPStore access
Submitted by: Rick McGuire

Added:
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java   (with props)
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java   (with props)
Modified:
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/IMAPStoreGBean.java
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPStoreGBean.java
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPTransportGBean.java
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/POP3StoreGBean.java
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/ProtocolGBean.java
    geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPTransportGBean.java
    geronimo/trunk/modules/mail/src/test/org/apache/geronimo/mail/MailGBeanTest.java

Modified: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/IMAPStoreGBean.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/IMAPStoreGBean.java?rev=387533&r1=387532&r2=387533&view=diff
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/IMAPStoreGBean.java (original)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/IMAPStoreGBean.java Tue Mar 21 06:14:15 2006
@@ -38,6 +38,48 @@
  */
 public class IMAPStoreGBean extends ProtocolGBean {
 
+    // the IMAP configuration property names
+    static public final String IMAP_PORT = "mail.imap.port";
+    static public final String IMAP_CONNECTION_TIMEOUT = "mail.imap.connectiontimeout";
+    static public final String IMAP_TIMEOUT = "mail.imap.timeout";
+    static public final String IMAP_FACTORY_CLASS = "mail.imap.socketFactory.class";
+    static public final String IMAP_FACTORY_FALLBACK = "mail.imap.socketFactory.fallback";
+    static public final String IMAP_FACTORY_PORT = "mail.imap.socketFactory.port";
+    static public final String IMAP_LOCALHOST = "mail.imap.localhost";
+    static public final String IMAP_LOCALADDRESS = "mail.imap.localaddress";
+    static public final String IMAP_LOCALPORT = "mail.imap.localport";
+    static public final String IMAP_PARTIAL_FETCH = "mail.imap.partialfetch";
+    static public final String IMAP_FETCH_SIZE = "mail.imap.fetchsize";
+    static public final String IMAP_STATUS_TIMEOUT = "mail.imap.statuscachetimeout";
+    static public final String IMAP_APPEND_SIZE = "mail.imap.appendbuffersize";
+    static public final String IMAP_POOL_SIZE = "mail.imap.connectionpoolsize";
+    static public final String IMAP_POOL_TIMEOUT = "mail.imap.connectionpooltimeout";
+    static public final String IMAP_SEPARATE_STORE_CONNECTION = "mail.imap.separatestoreconnection";
+    static public final String IMAP_READONLY_SELECT = "mail.imap.alloreadonlyselect";
+    static public final String IMAP_LOGIN_DISABLE = "mail.imap.auth.login.disable";
+    static public final String IMAP_PLAIN_DISABLE = "mail.imap.auth.plain.disable";
+    static public final String IMAP_STARTTLS_ENABLE = "mail.imap.auth.starttls.enable";
+    static public final String IMAP_SASL_ENABLE = "mail.imap.sasl.enable";
+    static public final String IMAP_SASL_MECHANISMS = "mail.imap.sasl.mechanisms";
+    static public final String IMAP_SASL_AUTHORIZATIONID = "mail.imap.sasl.authorizationid";
+
+
+    // the GBEAN property names
+    static public final String GBEAN_PARTIAL_FETCH = "partialFetch";
+    static public final String GBEAN_FETCH_SIZE = "fetchSize";
+    static public final String GBEAN_STATUS_TIMEOUT = "statusCacheTimeout";
+    static public final String GBEAN_APPEND_SIZE = "appendBufferSize";
+    static public final String GBEAN_POOL_SIZE = "connectionPoolSize";
+    static public final String GBEAN_POOL_TIMEOUT = "connectionPoolTimeout";
+    static public final String GBEAN_SEPARATE_STORE_CONNECTION = "separateStoreConnection";
+    static public final String GBEAN_READONLY_SELECT = "allowReadOnlySelect";
+    static public final String GBEAN_LOGIN_DISABLE = "authLoginDisable";
+    static public final String GBEAN_PLAIN_DISABLE = "authPlainDisable";
+    static public final String GBEAN_STARTTLS_ENABLE = "startTLSEnable";
+    static public final String GBEAN_SASL_ENABLE = "saslEnable";
+    static public final String GBEAN_SASL_MECHANISMS = "saslMechanisms";
+    static public final String GBEAN_SASL_AUTHORIZATIONID = "saslAuthorizationId";
+
     private final Log log = LogFactory.getLog(IMAPStoreGBean.class);
 
     private Integer port;
@@ -724,28 +766,28 @@
     public void addOverrides(Properties props) {
         super.addOverrides(props);
 
-        if (port != null) props.put("mail.imap.port", port);
-        if (partialFetch != null) props.put("mail.imap.partialfetch", partialFetch);
-        if (fetchSize != null) props.put("mail.imap.fetchsize", fetchSize);
-        if (connectionTimeout != null) props.put("mail.imap.connectiontimeout", connectionTimeout);
-        if (timeout != null) props.put("mail.imap.timeout", timeout);
-        if (statusCacheTimeout != null) props.put("mail.imap.statuscachetimeout", statusCacheTimeout);
-        if (appendBufferSize != null) props.put("mail.imap.appendbuffersize", appendBufferSize);
-        if (connectionPoolSize != null) props.put("mail.imap.connectionpoolsize", connectionPoolSize);
-        if (connectionPoolTimeout != null) props.put("mail.imap.connectionpooltimeout", connectionPoolTimeout);
-        if (separateStoreConnection != null) props.put("mail.imap.separatestoreconnection", separateStoreConnection);
-        if (allowReadOnlySelect != null) props.put("mail.imap.allowreadonlyselect", allowReadOnlySelect);
-        if (authLoginDisable != null) props.put("mail.imap.auth.login.disable", authLoginDisable);
-        if (authPlainDisable != null) props.put("mail.imap.auth.plain.disable", authPlainDisable);
-        if (startTLSEnable != null) props.put("mail.imap.auth.starttls.enable", startTLSEnable);
-        if (localaddress != null) props.put("mail.imap.localaddress", localaddress);
-        if (localport != null) props.put("mail.imap.localport", localport);
-        if (saslEnable != null) props.put("mail.imap.sasl.enable", saslEnable);
-        if (saslMechanisms != null) props.put("mail.imap.sasl.mechanisms", saslMechanisms);
-        if (saslAuthorizationId != null) props.put("mail.imap.sasl.authorizationid", saslAuthorizationId);
-        if (socketFactoryClass != null) props.put("mail.imap.socketFactory.class", socketFactoryClass);
-        if (socketFactoryFallback != null) props.put("mail.imap.socketFactory.fallback", socketFactoryFallback);
-        if (socketFactoryPort != null) props.put("mail.imap.socketFactory.port", socketFactoryPort);
+        if (port != null) props.put(IMAP_PORT, port);
+        if (partialFetch != null) props.put(IMAP_PARTIAL_FETCH, partialFetch);
+        if (fetchSize != null) props.put(IMAP_FETCH_SIZE, fetchSize);
+        if (connectionTimeout != null) props.put(IMAP_CONNECTION_TIMEOUT, connectionTimeout);
+        if (timeout != null) props.put(IMAP_TIMEOUT, timeout);
+        if (statusCacheTimeout != null) props.put(IMAP_STATUS_TIMEOUT, statusCacheTimeout);
+        if (appendBufferSize != null) props.put(IMAP_APPEND_SIZE, appendBufferSize);
+        if (connectionPoolSize != null) props.put(IMAP_POOL_SIZE, connectionPoolSize);
+        if (connectionPoolTimeout != null) props.put(IMAP_POOL_TIMEOUT, connectionPoolTimeout);
+        if (separateStoreConnection != null) props.put(IMAP_SEPARATE_STORE_CONNECTION, separateStoreConnection);
+        if (allowReadOnlySelect != null) props.put(IMAP_READONLY_SELECT, allowReadOnlySelect);
+        if (authLoginDisable != null) props.put(IMAP_LOGIN_DISABLE, authLoginDisable);
+        if (authPlainDisable != null) props.put(IMAP_PLAIN_DISABLE, authPlainDisable);
+        if (startTLSEnable != null) props.put(IMAP_STARTTLS_ENABLE, startTLSEnable);
+        if (localaddress != null) props.put(IMAP_LOCALADDRESS, localaddress);
+        if (localport != null) props.put(IMAP_LOCALPORT, localport);
+        if (saslEnable != null) props.put(IMAP_SASL_ENABLE, saslEnable);
+        if (saslMechanisms != null) props.put(IMAP_SASL_MECHANISMS, saslMechanisms);
+        if (saslAuthorizationId != null) props.put(IMAP_SASL_AUTHORIZATIONID, saslAuthorizationId);
+        if (socketFactoryClass != null) props.put(IMAP_FACTORY_CLASS, socketFactoryClass);
+        if (socketFactoryFallback != null) props.put(IMAP_FACTORY_FALLBACK, socketFactoryFallback);
+        if (socketFactoryPort != null) props.put(IMAP_FACTORY_PORT, socketFactoryPort);
     }
 
     public void doStart() throws Exception {
@@ -765,52 +807,59 @@
     static {
         GBeanInfoBuilder infoFactory = GBeanInfoBuilder.createStatic(IMAPStoreGBean.class, ProtocolGBean.GBEAN_INFO);
 
-        infoFactory.addAttribute("port", Integer.class, true);
-        infoFactory.addAttribute("partialFetch", Boolean.class, true);
-        infoFactory.addAttribute("fetchSize", Integer.class, true);
-        infoFactory.addAttribute("connectionTimeout", Integer.class, true);
-        infoFactory.addAttribute("timeout", Integer.class, true);
-        infoFactory.addAttribute("statusCacheTimeout", Integer.class, true);
-        infoFactory.addAttribute("appendBufferSize", Integer.class, true);
-        infoFactory.addAttribute("connectionPoolSize", Integer.class, true);
-        infoFactory.addAttribute("connectionPoolTimeout", Integer.class, true);
-        infoFactory.addAttribute("separateStoreConnection", Boolean.class, true);
-        infoFactory.addAttribute("allowReadOnlySelect", Boolean.class, true);
-        infoFactory.addAttribute("authLoginDisable", Boolean.class, true);
-        infoFactory.addAttribute("authPlainDisable", Boolean.class, true);
-        infoFactory.addAttribute("startTLSEnable", Boolean.class, true);
-        infoFactory.addAttribute("localaddress", String.class, true);
-        infoFactory.addAttribute("localport", Integer.class, true);
-        infoFactory.addAttribute("saslEnable", Boolean.class, true);
-        infoFactory.addAttribute("saslMechanisms", String.class, true);
-        infoFactory.addAttribute("saslAuthorizationId", String.class, true);
-        infoFactory.addAttribute("socketFactoryClass", String.class, true);
-        infoFactory.addAttribute("socketFactoryFallback", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryPort", Integer.class, true);
-
-        infoFactory.setConstructor(new String[]{"objectName", "properties", "host", "user",
-                                                "port",
-                                                "partialFetch",
-                                                "fetchSize",
-                                                "connectionTimeout",
-                                                "timeout",
-                                                "statusCacheTimeout",
-                                                "appendBufferSize",
-                                                "connectionPoolSize",
-                                                "connectionPoolTimeout",
-                                                "separateStoreConnection",
-                                                "allowReadOnlySelect",
-                                                "authLoginDisable",
-                                                "authPlainDisable",
-                                                "startTLSEnable",
-                                                "localaddress",
-                                                "localport",
-                                                "saslEnable",
-                                                "saslMechanisms",
-                                                "saslAuthorizationId",
-                                                "socketFactoryClass",
-                                                "socketFactoryFallback",
-                                                "socketFactoryPort"});
+        infoFactory.addAttribute(GBEAN_PORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_CONNECTION_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALADDRESS, String.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALPORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_CLASS, String.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_FALLBACK, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_PORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_PARTIAL_FETCH, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FETCH_SIZE, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_STATUS_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_APPEND_SIZE, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_POOL_SIZE, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_POOL_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_SEPARATE_STORE_CONNECTION, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_READONLY_SELECT, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_LOGIN_DISABLE, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_PLAIN_DISABLE, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_STARTTLS_ENABLE, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_SASL_ENABLE, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_SASL_MECHANISMS, String.class, true);
+        infoFactory.addAttribute(GBEAN_SASL_AUTHORIZATIONID, String.class, true);
+
+        infoFactory.addAttribute(GBEAN_OBJECTNAME, String.class, false);
+        infoFactory.addAttribute(GBEAN_PROTOCOL, String.class, true);
+        infoFactory.addAttribute(GBEAN_PROPERTIES, Properties.class, true);
+        infoFactory.addAttribute(GBEAN_HOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_USER, String.class, true);
+        infoFactory.addOperation(GBEAN_ADD_OVERRIDES, new Class[]{Properties.class});
+
+        infoFactory.setConstructor(new String[]{GBEAN_OBJECTNAME, GBEAN_PROPERTIES, GBEAN_HOST, GBEAN_USER,
+                                                GBEAN_PORT,
+                                                GBEAN_PARTIAL_FETCH,
+                                                GBEAN_FETCH_SIZE,
+                                                GBEAN_CONNECTION_TIMEOUT,
+                                                GBEAN_TIMEOUT,
+                                                GBEAN_STATUS_TIMEOUT,
+                                                GBEAN_APPEND_SIZE,
+                                                GBEAN_POOL_SIZE,
+                                                GBEAN_POOL_TIMEOUT,
+                                                GBEAN_SEPARATE_STORE_CONNECTION,
+                                                GBEAN_READONLY_SELECT,
+                                                GBEAN_LOGIN_DISABLE,
+                                                GBEAN_PLAIN_DISABLE,
+                                                GBEAN_STARTTLS_ENABLE,
+                                                GBEAN_LOCALADDRESS,
+                                                GBEAN_LOCALPORT,
+                                                GBEAN_SASL_ENABLE,
+                                                GBEAN_SASL_MECHANISMS,
+                                                GBEAN_SASL_AUTHORIZATIONID,
+                                                GBEAN_FACTORY_CLASS,
+                                                GBEAN_FACTORY_FALLBACK,
+                                                GBEAN_FACTORY_PORT});
 
         GBEAN_INFO = infoFactory.getBeanInfo();
     }

Added: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java?rev=387533&view=auto
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java (added)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java Tue Mar 21 06:14:15 2006
@@ -0,0 +1,39 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.mail;
+
+/**
+ * Common constants used by the two NNTP GBean classes.
+ * <p/>
+ *
+ * @version $Rev$ $Date$
+ */
+public interface NNTPGBeanConstants {
+
+    // the NNTP configuration property names
+    static public final String NNTP_PORT = "mail.nntp.port";
+    static public final String NNTP_CONNECTION_TIMEOUT = "mail.nntp.connectiontimeout";
+    static public final String NNTP_TIMEOUT = "mail.nntp.timeout";
+    static public final String NNTP_FROM = "mail.nntp.from";
+    static public final String NNTP_AUTH = "mail.nntp.auth";
+    static public final String NNTP_REALM = "mail.nntp.sasl.realm";
+    static public final String NNTP_QUITWAIT = "mail.nntp.quitwait";
+    static public final String NNTP_FACTORY_CLASS = "mail.nntp.socketFactory.class";
+    static public final String NNTP_FACTORY_FALLBACK = "mail.nntp.socketFactory.fallback";
+    static public final String NNTP_FACTORY_PORT = "mail.nntp.socketFactory.port";
+}
+

Propchange: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java
------------------------------------------------------------------------------
    svn:keywords = Date Rev

Propchange: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPGBeanConstants.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPStoreGBean.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPStoreGBean.java?rev=387533&r1=387532&r2=387533&view=diff
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPStoreGBean.java (original)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPStoreGBean.java Tue Mar 21 06:14:15 2006
@@ -36,7 +36,7 @@
  * @version $Rev$ $Date$
  * @see MailGBean
  */
-public class NNTPStoreGBean extends ProtocolGBean {
+public class NNTPStoreGBean extends ProtocolGBean implements NNTPGBeanConstants {
 
     private final Log log = LogFactory.getLog(NNTPTransportGBean.class);
 
@@ -319,15 +319,15 @@
     public void addOverrides(Properties props) {
         super.addOverrides(props);
 
-        if (port != null) props.put("mail.nntp.port", port);
-        if (connectionTimeout != null) props.put("mail.nntp.connectiontimeout", connectionTimeout);
-        if (timeout != null) props.put("mail.nntp.timeout", timeout);
-        if (auth != null) props.put("mail.nntp.auth", auth);
-        if (saslRealm != null) props.put("mail.nntp.sasl.realm", saslRealm);
-        if (quitWait != null) props.put("mail.nntp.quitwait", quitWait);
-        if (socketFactoryClass != null) props.put("mail.nntp.socketFactory.class", socketFactoryClass);
-        if (socketFactoryFallback != null) props.put("mail.nntp.socketFactory.fallback", socketFactoryFallback);
-        if (socketFactoryPort != null) props.put("mail.nntp.socketFactory.port", socketFactoryPort);
+        if (port != null) props.put(NNTP_PORT, port);
+        if (connectionTimeout != null) props.put(NNTP_CONNECTION_TIMEOUT, connectionTimeout);
+        if (timeout != null) props.put(NNTP_TIMEOUT, timeout);
+        if (auth != null) props.put(NNTP_AUTH, auth);
+        if (saslRealm != null) props.put(NNTP_REALM, saslRealm);
+        if (quitWait != null) props.put(NNTP_QUITWAIT, quitWait);
+        if (socketFactoryClass != null) props.put(NNTP_FACTORY_CLASS, socketFactoryClass);
+        if (socketFactoryFallback != null) props.put(NNTP_FACTORY_FALLBACK, socketFactoryFallback);
+        if (socketFactoryPort != null) props.put(NNTP_FACTORY_PORT, socketFactoryPort);
     }
 
     public void doStart() throws Exception {
@@ -347,33 +347,33 @@
     static {
         GBeanInfoBuilder infoFactory = GBeanInfoBuilder.createStatic(NNTPStoreGBean.class);
 
-        infoFactory.addAttribute("port", Integer.class, true);
-        infoFactory.addAttribute("connectionTimeout", Integer.class, true);
-        infoFactory.addAttribute("timeout", Integer.class, true);
-        infoFactory.addAttribute("auth", Boolean.class, true);
-        infoFactory.addAttribute("saslRealm", String.class, true);
-        infoFactory.addAttribute("quitWait", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryClass", String.class, true);
-        infoFactory.addAttribute("socketFactoryFallback", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryPort", Integer.class, true);
-
-        infoFactory.addAttribute("objectName", String.class, false);
-        infoFactory.addAttribute("protocol", String.class, false);
-        infoFactory.addAttribute("properties", Properties.class, true);
-        infoFactory.addAttribute("host", String.class, true);
-        infoFactory.addAttribute("user", String.class, true);
-        infoFactory.addOperation("addOverrides", new Class[]{Properties.class});
-
-        infoFactory.setConstructor(new String[]{"objectName", "properties", "host", "user",
-                                                "port",
-                                                "connectionTimeout",
-                                                "timeout",
-                                                "auth",
-                                                "saslRealm",
-                                                "quitWait",
-                                                "socketFactoryClass",
-                                                "socketFactoryFallback",
-                                                "socketFactoryPort"});
+        infoFactory.addAttribute(GBEAN_PORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_CONNECTION_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_AUTH, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_REALM, String.class, true);
+        infoFactory.addAttribute(GBEAN_QUITWAIT, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_CLASS, String.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_FALLBACK, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_PORT, Integer.class, true);
+
+        infoFactory.addAttribute(GBEAN_OBJECTNAME, String.class, false);
+        infoFactory.addAttribute(GBEAN_PROTOCOL, String.class, true);
+        infoFactory.addAttribute(GBEAN_PROPERTIES, Properties.class, true);
+        infoFactory.addAttribute(GBEAN_HOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_USER, String.class, true);
+        infoFactory.addOperation(GBEAN_ADD_OVERRIDES, new Class[]{Properties.class});
+
+        infoFactory.setConstructor(new String[]{GBEAN_OBJECTNAME, GBEAN_PROPERTIES, GBEAN_HOST, GBEAN_USER,
+                                                GBEAN_PORT,
+                                                GBEAN_CONNECTION_TIMEOUT,
+                                                GBEAN_TIMEOUT,
+                                                GBEAN_AUTH,
+                                                GBEAN_REALM,
+                                                GBEAN_QUITWAIT,
+                                                GBEAN_FACTORY_CLASS,
+                                                GBEAN_FACTORY_FALLBACK,
+                                                GBEAN_FACTORY_PORT});
 
         GBEAN_INFO = infoFactory.getBeanInfo();
     }

Modified: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPTransportGBean.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPTransportGBean.java?rev=387533&r1=387532&r2=387533&view=diff
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPTransportGBean.java (original)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/NNTPTransportGBean.java Tue Mar 21 06:14:15 2006
@@ -36,7 +36,7 @@
  * @version $Rev$ $Date$
  * @see MailGBean
  */
-public class NNTPTransportGBean extends ProtocolGBean {
+public class NNTPTransportGBean extends ProtocolGBean implements NNTPGBeanConstants {
 
     private final Log log = LogFactory.getLog(NNTPTransportGBean.class);
 
@@ -344,16 +344,16 @@
     public void addOverrides(Properties props) {
         super.addOverrides(props);
 
-        if (port != null) props.put("mail.nntp.port", port);
-        if (connectionTimeout != null) props.put("mail.nntp.connectiontimeout", connectionTimeout);
-        if (timeout != null) props.put("mail.nntp.timeout", timeout);
-        if (from != null) props.put("mail.nntp.from", from);
-        if (auth != null) props.put("mail.nntp.auth", auth);
-        if (saslRealm != null) props.put("mail.nntp.sasl.realm", saslRealm);
-        if (quitWait != null) props.put("mail.nntp.quitwait", quitWait);
-        if (socketFactoryClass != null) props.put("mail.nntp.socketFactory.class", socketFactoryClass);
-        if (socketFactoryFallback != null) props.put("mail.nntp.socketFactory.fallback", socketFactoryFallback);
-        if (socketFactoryPort != null) props.put("mail.nntp.socketFactory.port", socketFactoryPort);
+        if (port != null) props.put(NNTP_PORT, port);
+        if (connectionTimeout != null) props.put(NNTP_CONNECTION_TIMEOUT, connectionTimeout);
+        if (timeout != null) props.put(NNTP_TIMEOUT, timeout);
+        if (from != null) props.put(NNTP_FROM, from);
+        if (auth != null) props.put(NNTP_AUTH, auth);
+        if (saslRealm != null) props.put(NNTP_REALM, saslRealm);
+        if (quitWait != null) props.put(NNTP_QUITWAIT, quitWait);
+        if (socketFactoryClass != null) props.put(NNTP_FACTORY_CLASS, socketFactoryClass);
+        if (socketFactoryFallback != null) props.put(NNTP_FACTORY_FALLBACK, socketFactoryFallback);
+        if (socketFactoryPort != null) props.put(NNTP_FACTORY_PORT, socketFactoryPort);
     }
 
     public void doStart() throws Exception {
@@ -373,35 +373,35 @@
     static {
         GBeanInfoBuilder infoFactory = GBeanInfoBuilder.createStatic(NNTPTransportGBean.class);
 
-        infoFactory.addAttribute("port", Integer.class, true);
-        infoFactory.addAttribute("connectionTimeout", Integer.class, true);
-        infoFactory.addAttribute("timeout", Integer.class, true);
-        infoFactory.addAttribute("from", String.class, true);
-        infoFactory.addAttribute("auth", Boolean.class, true);
-        infoFactory.addAttribute("saslRealm", String.class, true);
-        infoFactory.addAttribute("quitWait", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryClass", String.class, true);
-        infoFactory.addAttribute("socketFactoryFallback", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryPort", Integer.class, true);
-
-        infoFactory.addAttribute("objectName", String.class, false);
-        infoFactory.addAttribute("protocol", String.class, false);
-        infoFactory.addAttribute("properties", Properties.class, true);
-        infoFactory.addAttribute("host", String.class, true);
-        infoFactory.addAttribute("user", String.class, true);
-        infoFactory.addOperation("addOverrides", new Class[]{Properties.class});
-
-        infoFactory.setConstructor(new String[]{"objectName", "properties", "host", "user",
-                                                "port",
-                                                "connectionTimeout",
-                                                "timeout",
-                                                "from",
-                                                "auth",
-                                                "saslRealm",
-                                                "quitWait",
-                                                "socketFactoryClass",
-                                                "socketFactoryFallback",
-                                                "socketFactoryPort"});
+        infoFactory.addAttribute(GBEAN_PORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_CONNECTION_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_AUTH, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FROM, String.class, true);
+        infoFactory.addAttribute(GBEAN_REALM, String.class, true);
+        infoFactory.addAttribute(GBEAN_QUITWAIT, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_CLASS, String.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_FALLBACK, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_PORT, Integer.class, true);
+
+        infoFactory.addAttribute(GBEAN_OBJECTNAME, String.class, false);
+        infoFactory.addAttribute(GBEAN_PROTOCOL, String.class, true);
+        infoFactory.addAttribute(GBEAN_PROPERTIES, Properties.class, true);
+        infoFactory.addAttribute(GBEAN_HOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_USER, String.class, true);
+        infoFactory.addOperation(GBEAN_ADD_OVERRIDES, new Class[]{Properties.class});
+
+        infoFactory.setConstructor(new String[]{GBEAN_OBJECTNAME, GBEAN_PROPERTIES, GBEAN_HOST, GBEAN_USER,
+                                                GBEAN_PORT,
+                                                GBEAN_CONNECTION_TIMEOUT,
+                                                GBEAN_TIMEOUT,
+                                                GBEAN_FROM,
+                                                GBEAN_AUTH,
+                                                GBEAN_REALM,
+                                                GBEAN_QUITWAIT,
+                                                GBEAN_FACTORY_CLASS,
+                                                GBEAN_FACTORY_FALLBACK,
+                                                GBEAN_FACTORY_PORT});
 
         GBEAN_INFO = infoFactory.getBeanInfo();
     }

Modified: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/POP3StoreGBean.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/POP3StoreGBean.java?rev=387533&r1=387532&r2=387533&view=diff
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/POP3StoreGBean.java (original)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/POP3StoreGBean.java Tue Mar 21 06:14:15 2006
@@ -39,6 +39,24 @@
  */
 public class POP3StoreGBean extends ProtocolGBean {
 
+    // the POP3 configuration property names
+    static public final String POP3_PORT = "mail.pop3.port";
+    static public final String POP3_CONNECTION_TIMEOUT = "mail.pop3.connectiontimeout";
+    static public final String POP3_TIMEOUT = "mail.pop3.timeout";
+    static public final String POP3_FACTORY_CLASS = "mail.pop3.socketFactory.class";
+    static public final String POP3_FACTORY_FALLBACK = "mail.pop3.socketFactory.fallback";
+    static public final String POP3_FACTORY_PORT = "mail.pop3.socketFactory.port";
+    static public final String POP3_LOCALHOST = "mail.pop3.localhost";
+    static public final String POP3_LOCALADDRESS = "mail.pop3.localaddress";
+    static public final String POP3_LOCALPORT = "mail.pop3.localport";
+    static public final String POP3_RESET = "mail.pop3.resetbeforequit";
+    static public final String POP3_MESSAGE_CLASS = "mail.pop3.message.class";
+    static public final String POP3_APOP = "mail.pop3.apop.enable";
+
+    static public final String GBEAN_RESET = "rsetBeforeQuit";
+    static public final String GBEAN_APOP = "apopEnable";
+    static public final String GBEAN_MESSAGE_CLASS = "messageClass";
+
     private final Log log = LogFactory.getLog(POP3StoreGBean.class);
 
     private Integer port;
@@ -398,17 +416,17 @@
     public void addOverrides(Properties props) {
         super.addOverrides(props);
 
-        if (port != null) props.put("mail.pop3.port", port);
-        if (connectionTimeout != null) props.put("mail.pop3.connectiontimeout", connectionTimeout);
-        if (timeout != null) props.put("mail.pop3.timeout", timeout);
-        if (rsetBeforeQuit != null) props.put("mail.pop3.rsetbeforequit", rsetBeforeQuit);
-        if (messageClass != null) props.put("mail.pop3.message.class", messageClass);
-        if (localaddress != null) props.put("mail.pop3.localaddress", localaddress);
-        if (localport != null) props.put("mail.pop3.localport", localport);
-        if (apopEnable != null) props.put("mail.pop3.apop.enable", apopEnable);
-        if (socketFactoryClass != null) props.put("mail.pop3.socketFactory.class", socketFactoryClass);
-        if (socketFactoryFallback != null) props.put("mail.pop3.socketFactory.fallback", socketFactoryFallback);
-        if (socketFactoryPort != null) props.put("mail.pop3.socketFactory.port", socketFactoryPort);
+        if (port != null) props.put(POP3_PORT, port);
+        if (connectionTimeout != null) props.put(POP3_CONNECTION_TIMEOUT, connectionTimeout);
+        if (timeout != null) props.put(POP3_TIMEOUT, timeout);
+        if (rsetBeforeQuit != null) props.put(POP3_RESET, rsetBeforeQuit);
+        if (messageClass != null) props.put(POP3_MESSAGE_CLASS, messageClass);
+        if (localaddress != null) props.put(POP3_LOCALADDRESS, localaddress);
+        if (localport != null) props.put(POP3_LOCALPORT, localport);
+        if (apopEnable != null) props.put(POP3_APOP, apopEnable);
+        if (socketFactoryClass != null) props.put(POP3_FACTORY_CLASS, socketFactoryClass);
+        if (socketFactoryFallback != null) props.put(POP3_FACTORY_FALLBACK, socketFactoryFallback);
+        if (socketFactoryPort != null) props.put(POP3_FACTORY_PORT, socketFactoryPort);
     }
 
     public void doStart() throws Exception {
@@ -428,30 +446,37 @@
     static {
         GBeanInfoBuilder infoFactory = GBeanInfoBuilder.createStatic(POP3StoreGBean.class, ProtocolGBean.GBEAN_INFO);
 
-        infoFactory.addAttribute("port", Integer.class, true);
-        infoFactory.addAttribute("connectionTimeout", Integer.class, true);
-        infoFactory.addAttribute("timeout", Integer.class, true);
-        infoFactory.addAttribute("rsetBeforeQuit", Boolean.class, true);
-        infoFactory.addAttribute("messageClass", String.class, true);
-        infoFactory.addAttribute("localaddress", String.class, true);
-        infoFactory.addAttribute("localport", Integer.class, true);
-        infoFactory.addAttribute("apopEnable", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryClass", String.class, true);
-        infoFactory.addAttribute("socketFactoryFallback", Boolean.class, true);
-        infoFactory.addAttribute("socketFactoryPort", Integer.class, true);
-
-        infoFactory.setConstructor(new String[]{"objectName", "properties", "host", "user",
-                                                "port",
-                                                "connectionTimeout",
-                                                "timeout",
-                                                "rsetBeforeQuit",
-                                                "messageClass",
-                                                "localaddress",
-                                                "localport",
-                                                "apopEnable",
-                                                "socketFactoryClass",
-                                                "socketFactoryFallback",
-                                                "socketFactoryPort"});
+        infoFactory.addAttribute(GBEAN_PORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_CONNECTION_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_RESET, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_MESSAGE_CLASS, String.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALADDRESS, String.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALPORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_APOP, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_CLASS, String.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_FALLBACK, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_PORT, Integer.class, true);
+
+        infoFactory.addAttribute(GBEAN_OBJECTNAME, String.class, false);
+        infoFactory.addAttribute(GBEAN_PROTOCOL, String.class, true);
+        infoFactory.addAttribute(GBEAN_PROPERTIES, Properties.class, true);
+        infoFactory.addAttribute(GBEAN_HOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_USER, String.class, true);
+        infoFactory.addOperation(GBEAN_ADD_OVERRIDES, new Class[]{Properties.class});
+
+        infoFactory.setConstructor(new String[]{GBEAN_OBJECTNAME, GBEAN_PROPERTIES, GBEAN_HOST, GBEAN_USER,
+                                                GBEAN_PORT,
+                                                GBEAN_CONNECTION_TIMEOUT,
+                                                GBEAN_TIMEOUT,
+                                                GBEAN_RESET,
+                                                GBEAN_MESSAGE_CLASS,
+                                                GBEAN_LOCALADDRESS,
+                                                GBEAN_LOCALPORT,
+                                                GBEAN_APOP,
+                                                GBEAN_FACTORY_CLASS,
+                                                GBEAN_FACTORY_FALLBACK,
+                                                GBEAN_FACTORY_PORT});
 
         GBEAN_INFO = infoFactory.getBeanInfo();
     }

Modified: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/ProtocolGBean.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/ProtocolGBean.java?rev=387533&r1=387532&r2=387533&view=diff
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/ProtocolGBean.java (original)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/ProtocolGBean.java Tue Mar 21 06:14:15 2006
@@ -35,6 +35,29 @@
  */
 public class ProtocolGBean implements GBeanLifecycle {
 
+    // common attributes exported by all ProtocolBeans
+    static public final String GBEAN_OBJECTNAME = "objectName";
+    static public final String GBEAN_PROTOCOL = "protocol";
+    static public final String GBEAN_PROPERTIES = "properties";
+    static public final String GBEAN_HOST = "host";
+    static public final String GBEAN_USER = "user";
+    static public final String GBEAN_ADD_OVERRIDES = "addOverrides";
+
+    // common constants for GBEAN properties that are used by a number of transports.
+    static public final String GBEAN_PORT = "port";
+    static public final String GBEAN_CONNECTION_TIMEOUT = "connectionTimeout";
+    static public final String GBEAN_TIMEOUT = "timeout";
+    static public final String GBEAN_FROM = "from";
+    static public final String GBEAN_AUTH = "auth";
+    static public final String GBEAN_REALM = "saslRealm";
+    static public final String GBEAN_QUITWAIT = "quitWait";
+    static public final String GBEAN_FACTORY_CLASS = "socketFactoryClass";
+    static public final String GBEAN_FACTORY_FALLBACK = "socketFactoryFallback";
+    static public final String GBEAN_FACTORY_PORT = "socketFactoryPort";
+    static public final String GBEAN_LOCALHOST = "localhost";
+    static public final String GBEAN_LOCALADDRESS = "localaddress";
+    static public final String GBEAN_LOCALPORT = "localport";
+
     private final Log log = LogFactory.getLog(ProtocolGBean.class);
 
     private final String objectName;
@@ -167,14 +190,14 @@
     static {
         GBeanInfoBuilder infoFactory = GBeanInfoBuilder.createStatic(ProtocolGBean.class); //TODO just a gbean?
 
-        infoFactory.addAttribute("objectName", String.class, false);
-        infoFactory.addAttribute("protocol", String.class, true);
-        infoFactory.addAttribute("properties", Properties.class, true);
-        infoFactory.addAttribute("host", String.class, true);
-        infoFactory.addAttribute("user", String.class, true);
-        infoFactory.addOperation("addOverrides", new Class[]{Properties.class});
+        infoFactory.addAttribute(GBEAN_OBJECTNAME, String.class, false);
+        infoFactory.addAttribute(GBEAN_PROTOCOL, String.class, true);
+        infoFactory.addAttribute(GBEAN_PROPERTIES, Properties.class, true);
+        infoFactory.addAttribute(GBEAN_HOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_USER, String.class, true);
+        infoFactory.addOperation(GBEAN_ADD_OVERRIDES, new Class[]{Properties.class});
 
-        infoFactory.setConstructor(new String[]{"objectName", "protocol", "properties", "host", "user"});
+        infoFactory.setConstructor(new String[]{GBEAN_OBJECTNAME, GBEAN_PROTOCOL, GBEAN_PROPERTIES, GBEAN_HOST, GBEAN_USER});
 
         GBEAN_INFO = infoFactory.getBeanInfo();
     }

Added: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java?rev=387533&view=auto
==============================================================================
--- geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java (added)
+++ geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java Tue Mar 21 06:14:15 2006
@@ -0,0 +1,873 @@
+/**
+ *
+ * Copyright 2006 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.mail;
+
+import java.util.Properties;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.apache.geronimo.gbean.GBeanInfo;
+import org.apache.geronimo.gbean.GBeanInfoBuilder;
+
+/**
+ * A GBean that provides for the configuration of a JavaMail SMTP transport
+ * protocol.
+ * <p/>
+ * SMTP transport properties that are common to all SMTP transports are
+ * provided via member variables of this class.  Values that are set in the
+ * individual member variables will override any of the corresponding values
+ * that have been set in the properties set.
+ *
+ * @version $Rev$ $Date$
+ * @see MailGBean
+ */
+public class SMTPSTransportGBean extends ProtocolGBean {
+
+    // the SMTPS configuration property names
+    static public final String SMTPS_PORT = "mail.smtp.port";
+    static public final String SMTPS_CONNECTION_TIMEOUT = "mail.smtp.connectiontimeout";
+    static public final String SMTPS_TIMEOUT = "mail.smtp.timeout";
+    static public final String SMTPS_FROM = "mail.smtp.from";
+    static public final String SMTPS_AUTH = "mail.smtp.auth";
+    static public final String SMTPS_REALM = "mail.smtp.sasl.realm";
+    static public final String SMTPS_QUITWAIT = "mail.smtp.quitwait";
+    static public final String SMTPS_FACTORY_CLASS = "mail.smtp.socketFactory.class";
+    static public final String SMTPS_FACTORY_FALLBACK = "mail.smtp.socketFactory.fallback";
+    static public final String SMTPS_FACTORY_PORT = "mail.smtp.socketFactory.port";
+    static public final String SMTPS_LOCALHOST = "mail.smtp.localhost";
+    static public final String SMTPS_LOCALADDRESS = "mail.smtp.localaddress";
+    static public final String SMTPS_LOCALPORT = "mail.smtp.localport";
+    static public final String SMTPS_EHLO = "mail.smtp.ehlo";
+    static public final String SMTPS_SUBMITTER = "mail.smtp.submitter";
+    static public final String SMTPS_DSN_NOTIFY = "mail.smtp.dsn.notify";
+    static public final String SMTPS_DSN_RET = "mail.smtp.dsn.ret";
+    static public final String SMTPS_8BITMIME = "mail.smtp.allow8bitmime";
+    static public final String SMTPS_SEND_PARTIAL = "mail.smtp.sendpartial";
+    static public final String SMTPS_REPORT_SUCCESS = "mail.smtp.reportsuccess";
+    static public final String SMTPS_MAIL_EXTENSION = "mail.smtp.mailextension";
+    static public final String SMTPS_STARTTLS_ENABLE = "mail.smtp.starttls.enable";
+
+    static public final String GBEAN_EHLO = "ehlo";
+    static public final String GBEAN_SUBMITTER = "submitter";
+    static public final String GBEAN_DSN_NOTIFY = "dsnNotify";
+    static public final String GBEAN_DSN_RET = "dsnRet";
+    static public final String GBEAN_8BITMIME = "allow8bitmime";
+    static public final String GBEAN_SEND_PARTIAL = "sendPartical";
+    static public final String GBEAN_REPORT_SUCCESS = "reportSuccess";
+    static public final String GBEAN_MAIL_EXTENSION = "mailExtension";
+    static public final String GBEAN_STARTTLS_ENABLE = "startTLSEnable";
+
+    private final Log log = LogFactory.getLog(SMTPSTransportGBean.class);
+
+    private Integer port;
+    private Integer connectionTimeout;
+    private Integer timeout;
+    private String from;
+    private String localhost;
+    private String localaddress;
+    private Integer localport;
+    private Boolean ehlo;
+    private Boolean auth;
+    private String submitter;
+    private String dsnNotify;
+    private String dsnRet;
+    private Boolean allow8bitmime;
+    private Boolean sendPartial;
+    private String saslRealm;
+    private Boolean quitWait;
+    private Boolean reportSuccess;
+    private String socketFactoryClass;
+    private Boolean socketFactoryFallback;
+    private Integer socketFactoryPort;
+    private String mailExtension;
+    private Boolean startTLSEnable;
+
+
+    /**
+     * Construct an instance of SMTPSTransportGBean
+     * <p/>
+     * Values that are set in the individual member variables will override any of
+     * the corresponding values that have been set in the properties set.
+     *
+     * @param objectName            the object name of the protocol
+     * @param properties            the set of default properties for the protocol
+     * @param host                  the host the protocol connects to
+     * @param user                  the default name for the protocol
+     * @param port                  the SMTPS server port
+     * @param connectionTimeout     the socket connection timeout value in milliseconds
+     * @param timeout               the socket I/O timeout value in milliseconds
+     * @param from                  the email address to use for SMTPS MAIL command
+     * @param localhost             the local host name used in the SMTPS HELO or EHLO command
+     * @param localaddress          the local address (host name) to bind to when creating the SMTPS socket
+     * @param localport             the local port number to bind to when creating the SMTPS socket
+     * @param ehlo                  whether an attempt will be made to sign on with the EHLO command
+     * @param auth                  whether an attempt will be made to authenticate the user using
+     *                              the AUTH command
+     * @param startTLSEnable          the flag that enables the use of the STARTTLS command (if supported by the server) to switch the connection to a TLS-protected connection before issuing any login commands
+     * @param submitter             the submitter to use in the AUTH tag in the MAIL FROM command
+     * @param dsnNotify             the NOTIFY option to the RCPT command
+     * @param dsnRet                the RET option to the MAIL command
+     * @param allow8bitmime         whether encodings are converted to use "8bit" under certain
+     *                              conditions
+     * @param sendPartial           whether to send email to valid addresses when others are invalid
+     * @param saslRealm             the realm to use with DIGEST-MD5 authentication
+     * @param quitWait              whether the transport will wait for the response to the QUIT command
+     * @param reportSuccess         whether the transport will include an SMTPAddressSucceededException
+     *                              for each address that is successful
+     * @param socketFactoryClass    the class that will be used to create SMTPS sockets
+     * @param socketFactoryFallback whether java.net.Socket class will be created if the specified
+     *                              socket factory class cannot be created
+     * @param socketFactoryPort     whether java.net.Socket class will be created if the specified
+     *                              socket factory class cannot be created
+     * @param mailExtension         the extension string to append to the MAIL command
+     */
+    public SMTPSTransportGBean(String objectName, Properties properties, String host, String user,
+                              Integer port,
+                              Integer connectionTimeout,
+                              Integer timeout,
+                              String from,
+                              String localhost,
+                              String localaddress,
+                              Integer localport,
+                              Boolean ehlo,
+                              Boolean auth,
+                              Boolean startTLSEnable,
+                              String submitter,
+                              String dsnNotify,
+                              String dsnRet,
+                              Boolean allow8bitmime,
+                              Boolean sendPartial,
+                              String saslRealm,
+                              Boolean quitWait,
+                              Boolean reportSuccess,
+                              String socketFactoryClass,
+                              Boolean socketFactoryFallback,
+                              Integer socketFactoryPort,
+                              String mailExtension) {
+        super(objectName, "smtps", properties, host, user);
+
+        setPort(port);
+        setConnectionTimeout(connectionTimeout);
+        setTimeout(timeout);
+        setFrom(from);
+        setLocalhost(localhost);
+        setLocaladdress(localaddress);
+        setLocalport(localport);
+        setEhlo(ehlo);
+        setAuth(auth);
+        setStartTLSEnable(startTLSEnable);
+        setSubmitter(submitter);
+        setDsnNotify(dsnNotify);
+        setDsnRet(dsnRet);
+        setAllow8bitmime(allow8bitmime);
+        setSendPartial(sendPartial);
+        setSaslRealm(saslRealm);
+        setQuitWait(quitWait);
+        setReportSuccess(reportSuccess);
+        setSocketFactoryClass(socketFactoryClass);
+        setSocketFactoryFallback(socketFactoryFallback);
+        setSocketFactoryPort(socketFactoryPort);
+        setMailExtension(mailExtension);
+    }
+
+    /**
+     * Returns the SMTP server port to connect to, if the connect() method
+     * doesn't explicitly specify one.
+     */
+    public Integer getPort() {
+        return port;
+    }
+
+    /**
+     * Sets the SMTP server port to connect to, if the connect() method
+     * doesn't explicitly specify one.
+     * <p/>
+     * Defaults to 25.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param port the SMTP server port to connect to
+     */
+    public void setPort(Integer port) {
+        this.port = port;
+    }
+
+    /**
+     * Returns the socket connection timeout value in milliseconds.
+     */
+    public Integer getConnectionTimeout() {
+        return connectionTimeout;
+    }
+
+    /**
+     * Sets the socket connection timeout value in milliseconds.
+     * <p/>
+     * Default is infinite timeout.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param connectionTimeout the socket connection timeout value in milliseconds.
+     */
+    public void setConnectionTimeout(Integer connectionTimeout) {
+        this.connectionTimeout = connectionTimeout;
+    }
+
+    /**
+     * Returns the socket I/O timeout value in milliseconds.
+     */
+    public Integer getTimeout() {
+        return timeout;
+    }
+
+    /**
+     * Sets the socket I/O timeout value in milliseconds.
+     * <p/>
+     * Default is infinite timeout.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param timeout the socket I/O timeout value in milliseconds
+     */
+    public void setTimeout(Integer timeout) {
+        this.timeout = timeout;
+    }
+
+    /**
+     * Returns the email address to use for SMTP MAIL command.
+     */
+    public String getFrom() {
+        return from;
+    }
+
+    /**
+     * Sets the email address to use for SMTP MAIL command
+     * <p/>
+     * Email address to use for SMTP MAIL command. This sets the envelope
+     * return address. Defaults to msg.getFrom() or InternetAddress.getLocalAddress().
+     * NOTE: mail.smtp.user was previously used for this.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param from the email address to use for SMTP MAIL command
+     */
+    public void setFrom(String from) {
+        this.from = from;
+    }
+
+    /**
+     * Returns the local host name used in the SMTP HELO or EHLO command.
+     */
+    public String getLocalhost() {
+        return localhost;
+    }
+
+    /**
+     * Sets the local host name used in the SMTP HELO or EHLO command.
+     * <p/>
+     * Local host name used in the SMTP HELO or EHLO command. Defaults to
+     * InetAddress.getLocalHost().getHostName(). Should not normally need to
+     * be set if your JDK and your name service are configured properly.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param localhost the local host name used in the SMTP HELO or EHLO command
+     */
+    public void setLocalhost(String localhost) {
+        this.localhost = localhost;
+    }
+
+    /**
+     * Returns the local address (host name) to bind to when creating the SMTP socket.
+     */
+    public String getLocaladdress() {
+        return localaddress;
+    }
+
+    /**
+     * Sets the local address (host name) to bind to when creating the SMTP socket.
+     * <p/>
+     * Local address (host name) to bind to when creating the SMTP socket.
+     * Defaults to the address picked by the Socket class. Should not normally
+     * need to be set, but useful with multi-homed hosts where it's important
+     * to pick a particular local address to bind to.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param localaddress the local address (host name) to bind to when creating the SMTP socket
+     */
+    public void setLocaladdress(String localaddress) {
+        this.localaddress = localaddress;
+    }
+
+    /**
+     * Returns the local port number to bind to when creating the SMTP socket.
+     */
+    public Integer getLocalport() {
+        return localport;
+    }
+
+    /**
+     * Sets the local port number to bind to when creating the SMTP socket.
+     * <p/>
+     * Local port number to bind to when creating the SMTP socket. Defaults to
+     * the port number picked by the Socket class.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param localport the local port number to bind to when creating the SMTP socket
+     */
+    public void setLocalport(Integer localport) {
+        this.localport = localport;
+    }
+
+    /**
+     * Returns whether an attempt will be made to sign on with the EHLO command.
+     * <p/>
+     * If false, do not attempt to sign on with the EHLO command. Normally
+     * failure of the EHLO command will fallback to the HELO command; this
+     * property exists only for servers that don't fail EHLO properly or don't
+     * implement EHLO properly.
+     */
+    public Boolean getEhlo() {
+        return ehlo;
+    }
+
+    /**
+     * Set whether an attempt will be made to sign on with the EHLO command.
+     * <p/>
+     * If false, do not attempt to sign on with the EHLO command. Normally
+     * failure of the EHLO command will fallback to the HELO command; this
+     * property exists only for servers that don't fail EHLO properly or don't
+     * implement EHLO properly.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param ehlo whether an attempt will be made to sign on with the EHLO command
+     */
+    public void setEhlo(Boolean ehlo) {
+        this.ehlo = ehlo;
+    }
+
+    /**
+     * Returns whether an attempt will be made to authenticate the user using
+     * the AUTH command.
+     * <p/>
+     * Defaults to false.
+     */
+    public Boolean getAuth() {
+        return auth;
+    }
+
+    /**
+     * Sets whether an attempt will be made to authenticate the user using
+     * the AUTH command.
+     * <p/>
+     * Defaults to false.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param auth whether an attempt will be made to authenticate the user using
+     *             the AUTH command.
+     */
+    public void setAuth(Boolean auth) {
+        this.auth = auth;
+    }
+
+    /**
+     * Returns the flag that enables the use of the STARTTLS command (if
+     * supported by the server) to switch the connection to a TLS-protected
+     * connection before issuing any login commands.
+     * <p/>
+     * If true, enables the use of the STARTTLS command (if supported by the
+     * server) to switch the connection to a TLS-protected connection before
+     * issuing any login commands. Note that an appropriate trust store must
+     * configured so that the client will trust the server's certificate.
+     * This feature only works on J2SE 1.4 and newer systems. Default is false.
+     */
+    public Boolean getStartTLSEnable() {
+        return startTLSEnable;
+    }
+
+    /**
+     * Sets the flag that enables the use of the STARTTLS command (if
+     * supported by the server) to switch the connection to a TLS-protected
+     * connection before issuing any login commands.
+     * <p/>
+     * If true, enables the use of the STARTTLS command (if supported by the
+     * server) to switch the connection to a TLS-protected connection before
+     * issuing any login commands. Note that an appropriate trust store must
+     * configured so that the client will trust the server's certificate.
+     * This feature only works on J2SE 1.4 and newer systems. Default is false.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param startTLSEnable the flag that enables the use of the STARTTLS command (if
+     *                       supported by the server) to switch the connection to a TLS-protected
+     *                       connection before issuing any login commands
+     */
+    public void setStartTLSEnable(Boolean startTLSEnable) {
+        this.startTLSEnable = startTLSEnable;
+    }
+
+    /**
+     * Returns the submitter to use in the AUTH tag in the MAIL FROM command.
+     * <p/>
+     * Typically used by a mail relay to pass along information about the
+     * original submitter of the message. See also the setSubmitter method of
+     * SMTPMessage. Mail clients typically do not use this.
+     */
+    public String getSubmitter() {
+        return submitter;
+    }
+
+    /**
+     * Sets the submitter to use in the AUTH tag in the MAIL FROM command.
+     * <p/>
+     * Typically used by a mail relay to pass along information about the
+     * original submitter of the message. See also the setSubmitter method of
+     * SMTPMessage. Mail clients typically do not use this.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param submitter the submitter to use in the AUTH tag in the MAIL FROM command
+     */
+    public void setSubmitter(String submitter) {
+        this.submitter = submitter;
+    }
+
+    /**
+     * Returns the NOTIFY option to the RCPT command.
+     * <p/>
+     * Either NEVER, or some combination of SUCCESS, FAILURE, and DELAY
+     * (separated by commas).
+     */
+    public String getDsnNotify() {
+        return dsnNotify;
+    }
+
+    /**
+     * Sets the NOTIFY option to the RCPT command
+     * <p/>
+     * Either NEVER, or some combination of SUCCESS, FAILURE, and DELAY
+     * (separated by commas).
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param dsnNotify the NOTIFY option to the RCPT command
+     */
+    public void setDsnNotify(String dsnNotify) {
+        this.dsnNotify = dsnNotify;
+    }
+
+    /**
+     * Returns the RET option to the MAIL command.
+     * <p/>
+     * Either FULL or HDRS.
+     */
+    public String getDsnRet() {
+        return dsnRet;
+    }
+
+    /**
+     * Sets the RET option to the MAIL command
+     * <p/>
+     * Either FULL or HDRS.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param dsnRet the RET option to the MAIL command
+     */
+    public void setDsnRet(String dsnRet) {
+        this.dsnRet = dsnRet;
+    }
+
+    /**
+     * Returns whether encodings are converted to use "8bit" under certain
+     * conditions.
+     * <p/>
+     * If set to true, and the server supports the 8BITMIME extension, text
+     * parts of messages that use the "quoted-printable" or "base64" encodings
+     * are converted to use "8bit" encoding if they follow the RFC2045 rules
+     * for 8bit text.
+     */
+    public Boolean getAllow8bitmime() {
+        return allow8bitmime;
+    }
+
+    /**
+     * Sets whether encodings are converted to use "8bit" under certain
+     * conditions.
+     * <p/>
+     * If set to true, and the server supports the 8BITMIME extension, text
+     * parts of messages that use the "quoted-printable" or "base64" encodings
+     * are converted to use "8bit" encoding if they follow the RFC2045 rules
+     * for 8bit text.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param allow8bitmime whether encodings are converted to use "8bit" under certain
+     *                      conditions
+     */
+    public void setAllow8bitmime(Boolean allow8bitmime) {
+        this.allow8bitmime = allow8bitmime;
+    }
+
+    /**
+     * Returns whether to send email to valid addresses when others are invalid.
+     * <p/>
+     * If set to true, and a message has some valid and some invalid addresses,
+     * send the message anyway, reporting the partial failure with a
+     * SendFailedException. If set to false (the default), the message is not
+     * sent to any of the recipients if there is an invalid recipient address.
+     */
+    public Boolean getSendPartial() {
+        return sendPartial;
+    }
+
+    /**
+     * Sets whether to send email to valid addresses when others are invalid.
+     * <p/>
+     * If set to true, and a message has some valid and some invalid addresses,
+     * send the message anyway, reporting the partial failure with a
+     * SendFailedException. If set to false (the default), the message is not
+     * sent to any of the recipients if there is an invalid recipient address.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param sendPartial whether to send email to valid addresses when others are invalid
+     */
+    public void setSendPartial(Boolean sendPartial) {
+        this.sendPartial = sendPartial;
+    }
+
+    /**
+     * Returns the realm to use with DIGEST-MD5 authentication.
+     */
+    public String getSaslRealm() {
+        return saslRealm;
+    }
+
+    /**
+     * Sets the realm to use with DIGEST-MD5 authentication.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param saslRealm the realm to use with DIGEST-MD5 authentication
+     */
+    public void setSaslRealm(String saslRealm) {
+        this.saslRealm = saslRealm;
+    }
+
+    /**
+     * Returns whether the transport will wait for the response to the QUIT command.
+     * <p/>
+     * If set to true, causes the transport to wait for the response to the QUIT
+     * command. If set to false (the default), the QUIT command is sent and the
+     * connection is immediately closed.
+     */
+    public Boolean getQuitWait() {
+        return quitWait;
+    }
+
+    /**
+     * Sets whether the transport will wait for the response to the QUIT command
+     * <p/>
+     * If set to true, causes the transport to wait for the response to the QUIT
+     * command. If set to false (the default), the QUIT command is sent and the
+     * connection is immediately closed.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param quitWait whether the transport will wait for the response to the QUIT command
+     */
+    public void setQuitWait(Boolean quitWait) {
+        this.quitWait = quitWait;
+    }
+
+    /**
+     * Returns whether the transport will include an SMTPAddressSucceededException
+     * for each address that is successful.
+     * <p/>
+     * Note also that this will cause a SendFailedException to be thrown from
+     * the sendMessage method of SMTPTransport even if all addresses were
+     * correct and the message was sent successfully.
+     */
+    public Boolean getReportSuccess() {
+        return reportSuccess;
+    }
+
+    /**
+     * Sets whether the transport will include an SMTPAddressSucceededException
+     * for each address that is successful.
+     * <p/>
+     * Note also that this will cause a SendFailedException to be thrown from
+     * the sendMessage method of SMTPTransport even if all addresses were
+     * correct and the message was sent successfully.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param reportSuccess whether the transport will include an SMTPAddressSucceededException
+     *                      for each address that is successful
+     */
+    public void setReportSuccess(Boolean reportSuccess) {
+        this.reportSuccess = reportSuccess;
+    }
+
+    /**
+     * Returns the class that will be used to create SMTP sockets.
+     * <p/>
+     * If set, specifies the name of a class that implements the
+     * javax.net.SocketFactory interface. This class will be used to create SMTP
+     * sockets.
+     */
+    public String getSocketFactoryClass() {
+        return socketFactoryClass;
+    }
+
+    /**
+     * Sets the class that will be used to create SMTP sockets.
+     * <p/>
+     * If set, specifies the name of a class that implements the
+     * javax.net.SocketFactory interface. This class will be used to create SMTP
+     * sockets.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param socketFactoryClass the class that will be used to create SMTP sockets
+     */
+    public void setSocketFactoryClass(String socketFactoryClass) {
+        this.socketFactoryClass = socketFactoryClass;
+    }
+
+    /**
+     * Returns whether java.net.Socket class will be created if the specified
+     * socket factory class cannot be created.
+     * <p/>
+     * If set to true, failure to create a socket using the specified socket
+     * factory class will cause the socket to be created using the
+     * java.net.Socket class. Defaults to true.
+     */
+    public Boolean getSocketFactoryFallback() {
+        return socketFactoryFallback;
+    }
+
+    /**
+     * Sets whether java.net.Socket class will be created if the specified
+     * socket factory class cannot be created.
+     * <p/>
+     * If set to true, failure to create a socket using the specified socket
+     * factory class will cause the socket to be created using the
+     * java.net.Socket class. Defaults to true.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param socketFactoryFallback whether java.net.Socket class will be created if the specified
+     *                              socket factory class cannot be created
+     */
+    public void setSocketFactoryFallback(Boolean socketFactoryFallback) {
+        this.socketFactoryFallback = socketFactoryFallback;
+    }
+
+    /**
+     * Returns the port to connect to when using the specified socket factory.
+     * <p/>
+     * Specifies the port to connect to when using the specified socket
+     * factory. If not set, the default port will be used.
+     */
+    public Integer getSocketFactoryPort() {
+        return socketFactoryPort;
+    }
+
+    /**
+     * Sets the port to connect to when using the specified socket factory.
+     * <p/>
+     * Specifies the port to connect to when using the specified socket
+     * factory. If not set, the default port will be used.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param socketFactoryPort the port to connect to when using the specified socket factory
+     */
+    public void setSocketFactoryPort(Integer socketFactoryPort) {
+        this.socketFactoryPort = socketFactoryPort;
+    }
+
+    /**
+     * Returns the extension string to append to the MAIL command.
+     * <p/>
+     * Extension string to append to the MAIL command. The extension string
+     * can be used to specify standard SMTP service extensions as well as
+     * vendor-specific extensions. Typically the application should use the
+     * SMTPTransport method supportsExtension to verify that the server
+     * supports the desired service extension. See RFC 1869 and other RFCs
+     * that define specific extensions.
+     */
+    public String getMailExtension() {
+        return mailExtension;
+    }
+
+    /**
+     * Sets the extension string to append to the MAIL command.
+     * <p/>
+     * Extension string to append to the MAIL command. The extension string
+     * can be used to specify standard SMTP service extensions as well as
+     * vendor-specific extensions. Typically the application should use the
+     * SMTPTransport method supportsExtension to verify that the server
+     * supports the desired service extension. See RFC 1869 and other RFCs
+     * that define specific extensions.
+     * <p/>
+     * Values that are set here will override any of the corresponding value
+     * that has been set in the properties.
+     *
+     * @param mailExtension the extension string to append to the MAIL command
+     */
+    public void setMailExtension(String mailExtension) {
+        this.mailExtension = mailExtension;
+    }
+
+    /**
+     * Add the overrides from the member variables to the properties file.
+     */
+    public void addOverrides(Properties props) {
+        super.addOverrides(props);
+
+        if (port != null) props.put(SMTPS_PORT, port);
+        if (connectionTimeout != null) props.put(SMTPS_CONNECTION_TIMEOUT, connectionTimeout);
+        if (timeout != null) props.put(SMTPS_TIMEOUT, timeout);
+        if (from != null) props.put(SMTPS_FROM, from);
+        if (localhost != null) props.put(SMTPS_LOCALHOST, localhost);
+        if (localaddress != null) props.put(SMTPS_LOCALADDRESS, localaddress);
+        if (localport != null) props.put(SMTPS_LOCALPORT, localport);
+        if (ehlo != null) props.put(SMTPS_EHLO, ehlo);
+        if (auth != null) props.put(SMTPS_AUTH, auth);
+        if (startTLSEnable != null) props.put(SMTPS_STARTTLS_ENABLE, startTLSEnable);
+        if (submitter != null) props.put(SMTPS_SUBMITTER, submitter);
+        if (dsnNotify != null) props.put(SMTPS_DSN_NOTIFY, dsnNotify);
+        if (dsnRet != null) props.put(SMTPS_DSN_RET, dsnRet);
+        if (allow8bitmime != null) props.put(SMTPS_8BITMIME, allow8bitmime);
+        if (sendPartial != null) props.put(SMTPS_SEND_PARTIAL, sendPartial);
+        if (saslRealm != null) props.put(SMTPS_REALM, saslRealm);
+        if (quitWait != null) props.put(SMTPS_QUITWAIT, quitWait);
+        if (reportSuccess != null) props.put(SMTPS_REPORT_SUCCESS, reportSuccess);
+        if (socketFactoryClass != null) props.put(SMTPS_FACTORY_CLASS, socketFactoryClass);
+        if (socketFactoryFallback != null) props.put(SMTPS_FACTORY_FALLBACK, socketFactoryFallback);
+        if (socketFactoryPort != null) props.put(SMTPS_FACTORY_PORT, socketFactoryPort);
+        if (mailExtension != null) props.put(SMTPS_MAIL_EXTENSION, mailExtension);
+    }
+
+    public void doStart() throws Exception {
+        log.debug("Started " + getObjectName());
+    }
+
+    public void doStop() throws Exception {
+        log.debug("Stopped " + getObjectName());
+    }
+
+    public void doFail() {
+        log.warn("Failed " + getObjectName());
+    }
+
+    public static final GBeanInfo GBEAN_INFO;
+
+    static {
+        GBeanInfoBuilder infoFactory = GBeanInfoBuilder.createStatic(SMTPSTransportGBean.class);
+
+        infoFactory.addAttribute(GBEAN_PORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_CONNECTION_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_TIMEOUT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_AUTH, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_STARTTLS_ENABLE, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_EHLO, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FROM, String.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALHOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALADDRESS, String.class, true);
+        infoFactory.addAttribute(GBEAN_LOCALPORT, Integer.class, true);
+        infoFactory.addAttribute(GBEAN_REALM, String.class, true);
+        infoFactory.addAttribute(GBEAN_QUITWAIT, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_CLASS, String.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_FALLBACK, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_FACTORY_PORT, Integer.class, true);
+
+        infoFactory.addAttribute(GBEAN_SUBMITTER, String.class, true);
+        infoFactory.addAttribute(GBEAN_DSN_NOTIFY, String.class, true);
+        infoFactory.addAttribute(GBEAN_DSN_RET, String.class, true);
+        infoFactory.addAttribute(GBEAN_8BITMIME, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_SEND_PARTIAL, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_REPORT_SUCCESS, Boolean.class, true);
+        infoFactory.addAttribute(GBEAN_MAIL_EXTENSION, String.class, true);
+
+        infoFactory.addAttribute(GBEAN_OBJECTNAME, String.class, false);
+        infoFactory.addAttribute(GBEAN_PROTOCOL, String.class, true);
+        infoFactory.addAttribute(GBEAN_PROPERTIES, Properties.class, true);
+        infoFactory.addAttribute(GBEAN_HOST, String.class, true);
+        infoFactory.addAttribute(GBEAN_USER, String.class, true);
+        infoFactory.addOperation(GBEAN_ADD_OVERRIDES, new Class[]{Properties.class});
+
+        infoFactory.setConstructor(new String[]{GBEAN_OBJECTNAME, GBEAN_PROPERTIES, GBEAN_HOST, GBEAN_USER,
+                                                GBEAN_PORT,
+                                                GBEAN_CONNECTION_TIMEOUT,
+                                                GBEAN_TIMEOUT,
+                                                GBEAN_FROM,
+                                                GBEAN_LOCALHOST,
+                                                GBEAN_LOCALADDRESS,
+                                                GBEAN_LOCALPORT,
+                                                GBEAN_EHLO,
+                                                GBEAN_AUTH,
+                                                GBEAN_STARTTLS_ENABLE,
+                                                GBEAN_SUBMITTER,
+                                                GBEAN_DSN_NOTIFY,
+                                                GBEAN_DSN_RET,
+                                                GBEAN_8BITMIME,
+                                                GBEAN_SEND_PARTIAL,
+                                                GBEAN_REALM,
+                                                GBEAN_QUITWAIT,
+                                                GBEAN_REPORT_SUCCESS,
+                                                GBEAN_FACTORY_CLASS,
+                                                GBEAN_FACTORY_FALLBACK,
+                                                GBEAN_FACTORY_PORT,
+                                                GBEAN_MAIL_EXTENSION});
+
+        GBEAN_INFO = infoFactory.getBeanInfo();
+    }
+
+    public static GBeanInfo getGBeanInfo() {
+        return GBEAN_INFO;
+    }
+}
+

Propchange: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java
------------------------------------------------------------------------------
    svn:keywords = Date Rev

Propchange: geronimo/trunk/modules/mail/src/java/org/apache/geronimo/mail/SMTPSTransportGBean.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain



Mime
View raw message