You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by no...@apache.org on 2007/01/18 10:14:49 UTC

svn commit: r497364 - in /james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core: ./ esmtp/

Author: norman
Date: Thu Jan 18 01:14:48 2007
New Revision: 497364

URL: http://svn.apache.org/viewvc?view=rev&rev=497364
Log:
Just some formatting etc

Modified:
    james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/AbstractHookableCmdHandler.java
    james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataCmdHandler.java
    james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineFilter.java
    james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineMessageHookHandler.java
    james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/AuthCmdHandler.java
    james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/MailSizeEsmtpExtension.java

Modified: james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/AbstractHookableCmdHandler.java
URL: http://svn.apache.org/viewvc/james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/AbstractHookableCmdHandler.java?view=diff&rev=497364&r1=497363&r2=497364
==============================================================================
--- james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/AbstractHookableCmdHandler.java (original)
+++ james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/AbstractHookableCmdHandler.java Thu Jan 18 01:14:48 2007
@@ -147,7 +147,7 @@
     
                 return new SMTPResponse(smtpRetCode, smtpDesc);
             } else {
-                // TODO !? What do we have to do? Is there a default?
+                // Return null as default
                 return null;
             }
         } else {

Modified: james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataCmdHandler.java
URL: http://svn.apache.org/viewvc/james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataCmdHandler.java?view=diff&rev=497364&r1=497363&r2=497364
==============================================================================
--- james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataCmdHandler.java (original)
+++ james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataCmdHandler.java Thu Jan 18 01:14:48 2007
@@ -294,7 +294,6 @@
 
 
     /**
-     * @throws WiringException 
      * @see org.apache.james.smtpserver.ExtensibleHandler#wireExtensions(java.lang.Class, java.util.List)
      */
     public void wireExtensions(Class interfaceName, List extension) throws WiringException {

Modified: james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineFilter.java
URL: http://svn.apache.org/viewvc/james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineFilter.java?view=diff&rev=497364&r1=497363&r2=497364
==============================================================================
--- james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineFilter.java (original)
+++ james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineFilter.java Thu Jan 18 01:14:48 2007
@@ -1,6 +1,24 @@
-/**
- * 
- */
+/****************************************************************
+ * Licensed to the Apache Software Foundation (ASF) under one   *
+ * or more contributor license agreements.  See the NOTICE file *
+ * distributed with this work for additional information        *
+ * regarding copyright ownership.  The ASF licenses this file   *
+ * to you 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.james.smtpserver.core;
 
 import org.apache.james.smtpserver.LineHandler;

Modified: james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineMessageHookHandler.java
URL: http://svn.apache.org/viewvc/james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineMessageHookHandler.java?view=diff&rev=497364&r1=497363&r2=497364
==============================================================================
--- james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineMessageHookHandler.java (original)
+++ james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/DataLineMessageHookHandler.java Thu Jan 18 01:14:48 2007
@@ -1,6 +1,24 @@
-/**
- * 
- */
+/****************************************************************
+ * Licensed to the Apache Software Foundation (ASF) under one   *
+ * or more contributor license agreements.  See the NOTICE file *
+ * distributed with this work for additional information        *
+ * regarding copyright ownership.  The ASF licenses this file   *
+ * to you 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.james.smtpserver.core;
 
 import java.io.IOException;
@@ -34,6 +52,9 @@
     
     private List rHooks;
     
+    /**
+     * @see org.apache.james.smtpserver.core.DataLineFilter#onLine(org.apache.james.smtpserver.SMTPSession, byte[], org.apache.james.smtpserver.LineHandler)
+     */
     public void onLine(SMTPSession session, byte[] line, LineHandler next) {
         MimeMessageInputStreamSource mmiss = (MimeMessageInputStreamSource) session.getState().get(DataCmdHandler.DATA_MIMEMESSAGE_STREAMSOURCE);
         OutputStream out = (OutputStream)  session.getState().get(DataCmdHandler.DATA_MIMEMESSAGE_OUTPUTSTREAM);
@@ -135,7 +156,6 @@
     }
     
     /**
-     * @throws WiringException 
      * @see org.apache.james.smtpserver.ExtensibleHandler#wireExtensions(java.lang.Class, java.util.List)
      */
     public void wireExtensions(Class interfaceName, List extension) throws WiringException {

Modified: james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/AuthCmdHandler.java
URL: http://svn.apache.org/viewvc/james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/AuthCmdHandler.java?view=diff&rev=497364&r1=497363&r2=497364
==============================================================================
--- james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/AuthCmdHandler.java (original)
+++ james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/AuthCmdHandler.java Thu Jan 18 01:14:48 2007
@@ -368,7 +368,7 @@
     
                 return new SMTPResponse(smtpRetCode, smtpDesc);
             } else {
-                // TODO !? What do we have to do? Is there a default?
+                // Return null as default
                 return null;
             }
         } else {

Modified: james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/MailSizeEsmtpExtension.java
URL: http://svn.apache.org/viewvc/james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/MailSizeEsmtpExtension.java?view=diff&rev=497364&r1=497363&r2=497364
==============================================================================
--- james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/MailSizeEsmtpExtension.java (original)
+++ james/server/sandbox/handlerapi-experiment/src/java/org/apache/james/smtpserver/core/esmtp/MailSizeEsmtpExtension.java Thu Jan 18 01:14:48 2007
@@ -78,9 +78,8 @@
         try {
             size = Integer.parseInt(mailOptionValue);
         } catch (NumberFormatException pe) {
-            getLogger()
-                    .error(
-                            "Rejected syntactically incorrect value for SIZE parameter.");
+            getLogger().error("Rejected syntactically incorrect value for SIZE parameter.");
+            
             // This is a malformed option value. We return an error
             return new HookResult(HookReturnCode.DENY, 
                     SMTPRetCode.SYNTAX_ERROR_ARGUMENTS,
@@ -120,6 +119,9 @@
         return null;
     }
 
+    /**
+     * @see org.apache.james.smtpserver.core.DataLineFilter#onLine(org.apache.james.smtpserver.SMTPSession, byte[], org.apache.james.smtpserver.LineHandler)
+     */
     public void onLine(SMTPSession session, byte[] line, LineHandler next) {
         Boolean failed = (Boolean) session.getState().get(MESG_FAILED);
         // If we already defined we failed and sent a reply we should simply
@@ -156,6 +158,9 @@
         }
     }
 
+    /**
+     * @see org.apache.james.smtpserver.hook.MessageHook#onMessage(org.apache.james.smtpserver.SMTPSession, org.apache.mailet.Mail)
+     */
     public HookResult onMessage(SMTPSession session, Mail mail) {
         Boolean failed = (Boolean) session.getState().get(MESG_FAILED);
         if (failed != null && failed.booleanValue()) {



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org