You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-dev@jakarta.apache.org by ma...@apache.org on 2004/01/29 08:22:23 UTC

cvs commit: jakarta-taglibs/mailer/src/org/apache/taglibs/mailer AddRecipientTag.java AttachTag.java ErrorTEI.java ErrorTag.java FromTag.java HeaderTag.java MailAuthenticator.java MailTag.java MessageTag.java PasswordTag.java PortTag.java ReplyToTag.java SendTag.java ServerTag.java SetRecipientTag.java SubjectTag.java UserTag.java

martinc     2004/01/28 23:22:23

  Modified:    mailer/src/org/apache/taglibs/mailer AddRecipientTag.java
                        AttachTag.java ErrorTEI.java ErrorTag.java
                        FromTag.java HeaderTag.java MailAuthenticator.java
                        MailTag.java MessageTag.java PasswordTag.java
                        PortTag.java ReplyToTag.java SendTag.java
                        ServerTag.java SetRecipientTag.java SubjectTag.java
                        UserTag.java
  Log:
  General code cleanup, with help from IDEA:
   * Use explicit imports in preference to '*' imports.
   * Correct Javadoc comments, so that they match the code.
   * Remove unused code.
  
  Revision  Changes    Path
  1.8       +15 -14    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/AddRecipientTag.java
  
  Index: AddRecipientTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/AddRecipientTag.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- AddRecipientTag.java	3 Dec 2002 16:08:19 -0000	1.7
  +++ AddRecipientTag.java	29 Jan 2004 07:22:22 -0000	1.8
  @@ -61,15 +61,16 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.JspTagException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
  - * AddRecipientTag - JSP tag <b>addrecipient</b> is used to add any type of 
  - *                recipient to an already existant list of recipients in an 
  + * AddRecipientTag - JSP tag <b>addrecipient</b> is used to add any type of
  + *                recipient to an already existant list of recipients in an
    *                e-mail message. Two attributes are required, type and address.
  - *                Type may be either "to", "cc", or "bcc" and address should be 
  + *                Type may be either "to", "cc", or "bcc" and address should be
    *                a string representation of the recipients e-mail address.
    *
    * <tag>
  @@ -115,7 +116,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do at the start of this tag
        *
  -     *  @throws JSPTagException  thrown when an error occurs while processing the
  +     *  @throws JspTagException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  @@ -137,7 +138,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  @@ -162,7 +163,7 @@
       /**
        * set the type of recipient for the address
        *
  -     * @param type  string that is the type of the address either 
  +     * @param type  string that is the type of the address either
        *   "to", "cc", or "bcc".
        */
       public final void setType(String type) throws JspTagException {
  @@ -182,7 +183,7 @@
       /**
        * set the value for an address to be later added to the email
        *
  -     * @param address  string that is an address to be added to the 
  +     * @param address  string that is an address to be added to the
        *   "to", "cc", or "bcc" lists of addresses.
        */
       public final void setAddress(String address) {
  @@ -191,7 +192,7 @@
   
       private void addToParent(String addr) throws JspTagException {
         // parent tag must be a MailTag, gives access to methods in parent
  -      MailTag myparent = 
  +      MailTag myparent =
             (MailTag)findAncestorWithClass
                 (this, MailTag.class);
   
  
  
  
  1.7       +12 -15    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/AttachTag.java
  
  Index: AttachTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/AttachTag.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- AttachTag.java	3 Dec 2002 16:08:19 -0000	1.6
  +++ AttachTag.java	29 Jan 2004 07:22:22 -0000	1.7
  @@ -61,15 +61,16 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import java.net.URL;
  -import java.net.MalformedURLException;
   import java.io.File;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  -import javax.activation.*;
  +import java.net.MalformedURLException;
  +import java.net.URL;
  +import javax.activation.DataHandler;
  +import javax.activation.DataSource;
  +import javax.activation.FileDataSource;
   import javax.mail.MessagingException;
  -import javax.mail.internet.*;
  +import javax.mail.internet.MimeBodyPart;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   
   /**
  @@ -152,7 +153,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  @@ -269,8 +270,6 @@
        *
        * @param value  string that represents a URL
        *
  -     * @returns = MimeBodyPart that is added to the list of attachments
  -     *
        */
       private final void setUrlBodyPart(String value) throws JspException {
   
  @@ -299,8 +298,6 @@
        * mimebodypart to be added to the list of attachments
        *
        * @param value  string that represents a file path
  -     *
  -     * @returns = MimeBodyPart that is added to the list of attachments
        *
        */
       private final void setFileBodyPart(String value)  throws JspException {
  
  
  
  1.2       +6 -5      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ErrorTEI.java
  
  Index: ErrorTEI.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ErrorTEI.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ErrorTEI.java	31 Mar 2001 03:10:36 -0000	1.1
  +++ ErrorTEI.java	29 Jan 2004 07:22:22 -0000	1.2
  @@ -61,8 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import javax.servlet.jsp.tagext.*;
  -import org.apache.taglibs.mailer.*;
  +import javax.servlet.jsp.tagext.TagData;
  +import javax.servlet.jsp.tagext.TagExtraInfo;
  +import javax.servlet.jsp.tagext.VariableInfo;
   
   /**
    * TagExtraInfo for <b>error</b> tag, allows use of standard
  
  
  
  1.8       +12 -11    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ErrorTag.java
  
  Index: ErrorTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ErrorTag.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- ErrorTag.java	3 Dec 2002 16:08:19 -0000	1.7
  +++ ErrorTag.java	29 Jan 2004 07:22:22 -0000	1.8
  @@ -61,10 +61,11 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import java.io.IOException;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import java.util.ArrayList;
  +import java.util.Iterator;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.PageContext;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * ErrorTag - JSP tag <b>Error</b> is used to get the error message when creating
  @@ -100,7 +101,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do when the start tag is encountered
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return - SKIP_BODY if no errors exist, EVAL_BODY_TAG if errors do exist
  @@ -136,11 +137,11 @@
       }
   
       /**
  -     * Implementation of the method from the tag interface that gets called at 
  +     * Implementation of the method from the tag interface that gets called at
        * end of each error tag.
        *
        * @return EVAL_BODY_TAG if there is another error, or SKIP_BODY if there
  -     *                      are no more errors 
  +     *                      are no more errors
        */
       public final int doAfterBody() throws JspException
       {
  @@ -161,7 +162,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do when the start tag is encountered
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return - EVAL_PAGE
  
  
  
  1.4       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/FromTag.java
  
  Index: FromTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/FromTag.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- FromTag.java	3 Dec 2002 16:08:19 -0000	1.3
  +++ FromTag.java	29 Jan 2004 07:22:22 -0000	1.4
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * FromTag - JSP tag <b>From</b> is used to set the from address in an email.
  @@ -88,7 +88,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.6       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/HeaderTag.java
  
  Index: HeaderTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/HeaderTag.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- HeaderTag.java	3 Dec 2002 16:08:19 -0000	1.5
  +++ HeaderTag.java	29 Jan 2004 07:22:22 -0000	1.6
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * HeaderTag - JSP tag <b>Header</b> is used to set headers in an e-mail message.
  @@ -107,7 +107,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.5       +10 -11    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/MailAuthenticator.java
  
  Index: MailAuthenticator.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/MailAuthenticator.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- MailAuthenticator.java	23 Feb 2002 19:30:35 -0000	1.4
  +++ MailAuthenticator.java	29 Jan 2004 07:22:22 -0000	1.5
  @@ -61,12 +61,11 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.io.IOException;
  -import java.util.*;
   import java.awt.*;
  -import java.awt.event.*;
  -import javax.mail.*;
  -import javax.mail.internet.*;
  +import java.awt.event.ActionEvent;
  +import java.awt.event.ActionListener;
  +import javax.mail.Authenticator;
  +import javax.mail.PasswordAuthentication;
   
   /****************************************************************************
    *
  @@ -87,7 +86,7 @@
        * The users password used for basic authentication
        */
       protected String m_password = null;
  -	
  +
       /**
        * constructor calls the super class constructor
        *
  @@ -121,7 +120,7 @@
   		return new PasswordAuthentication(m_user, m_password);
   	}
   
  -	final Dialog dialog = new Dialog(new Frame("Login"), 
  +	final Dialog dialog = new Dialog(new Frame("Login"),
   				     "Please Login to the mail server", true);
   	dialog.setBounds(200, 200, 200, 100);
   	dialog.setLayout(new GridLayout (0, 1));
  @@ -143,7 +142,7 @@
   	    });
   	dialog.pack();
   	dialog.setVisible(true);
  -	return new PasswordAuthentication(username.getText(), 
  +	return new PasswordAuthentication(username.getText(),
   					          password.getText());
       }
   }
  
  
  
  1.13      +18 -13    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/MailTag.java
  
  Index: MailTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/MailTag.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- MailTag.java	29 Jan 2004 06:29:00 -0000	1.12
  +++ MailTag.java	29 Jan 2004 07:22:22 -0000	1.13
  @@ -61,13 +61,18 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
   import java.io.IOException;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  -import javax.naming.*;
  -import javax.mail.*;
  -import javax.mail.internet.*;
  +import java.util.ArrayList;
  +import java.util.Properties;
  +import javax.mail.Session;
  +import javax.mail.internet.MimeBodyPart;
  +import javax.mail.internet.MimeMessage;
  +import javax.mail.internet.MimePartDataSource;
  +import javax.naming.Context;
  +import javax.naming.InitialContext;
  +import javax.naming.NamingException;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * MailTag - JSP tag <b>Mail</b> is used to construct an email message.
  @@ -277,7 +282,7 @@
   
       /**
        * flag that determines if the session for sending mail should have an
  -     * authenticator so that user name and password can be entered if it is 
  +     * authenticator so that user name and password can be entered if it is
        * required for the mail server
        */
       private boolean authentication = false;
  @@ -300,11 +305,11 @@
               addTO.append(to);
           }
           addCC.setLength(0);
  -        if (cc != null) { 
  +        if (cc != null) {
               addCC.append(cc);
           }
           addBCC.setLength(0);
  -        if (bcc != null) { 
  +        if (bcc != null) {
               addBCC.append(bcc);
           }
           reset_from = null;
  @@ -368,7 +373,7 @@
                   // create mail message using preexisting jndi named message
                   MimePartDataSource mds =
                                    (MimePartDataSource)ctx.lookup(mimemessage);
  -                sessionobj = (Session)mds.getMessageContext().getSession();
  +                sessionobj = mds.getMessageContext().getSession();
                   message = new MimeMessage(sessionobj);
               } catch (NamingException ne) {
                   throw new JspException("Naming Exception " +
  
  
  
  1.8       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/MessageTag.java
  
  Index: MessageTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/MessageTag.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- MessageTag.java	29 Jan 2004 06:18:11 -0000	1.7
  +++ MessageTag.java	29 Jan 2004 07:22:22 -0000	1.8
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * MessageTag - JSP tag <b>Message</b> is used to set the message in an e-mail.
  @@ -108,7 +108,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.2       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/PasswordTag.java
  
  Index: PasswordTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/PasswordTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- PasswordTag.java	11 Nov 2003 05:27:00 -0000	1.1
  +++ PasswordTag.java	29 Jan 2004 07:22:22 -0000	1.2
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * PasswordTag - JSP tag <b>Password</b> is used to set the password used for
  @@ -89,7 +89,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.2       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/PortTag.java
  
  Index: PortTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/PortTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- PortTag.java	29 Jan 2004 05:19:26 -0000	1.1
  +++ PortTag.java	29 Jan 2004 07:22:22 -0000	1.2
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * PortTag - JSP tag <b>port</b> is used for dynamically setting the mail
  @@ -94,7 +94,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.6       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ReplyToTag.java
  
  Index: ReplyToTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ReplyToTag.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- ReplyToTag.java	3 Dec 2002 16:08:19 -0000	1.5
  +++ ReplyToTag.java	29 Jan 2004 07:22:22 -0000	1.6
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * ReplyToTag - JSP tag <b>ReplyTo</b> is used to set the To address in an e-mail.
  @@ -88,7 +88,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.16      +28 -23    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/SendTag.java
  
  Index: SendTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/SendTag.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- SendTag.java	29 Jan 2004 06:18:11 -0000	1.15
  +++ SendTag.java	29 Jan 2004 07:22:22 -0000	1.16
  @@ -61,13 +61,19 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import java.io.IOException;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  -import javax.mail.*;
  -import javax.mail.internet.*;
  -import javax.activation.DataHandler;
  +import java.util.ArrayList;
  +import java.util.Date;
  +import java.util.ListIterator;
  +import javax.mail.Message;
  +import javax.mail.MessagingException;
  +import javax.mail.Transport;
  +import javax.mail.internet.AddressException;
  +import javax.mail.internet.InternetAddress;
  +import javax.mail.internet.MimeBodyPart;
  +import javax.mail.internet.MimeMessage;
  +import javax.mail.internet.MimeMultipart;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * SendTag - JSP tag <b>Send</b> is used to send the created email.
  @@ -108,7 +114,6 @@
   // Added by Jayson Falkner - 5/8/2001 --------------------------
   	MimeMultipart multipart; // multipart for this message
   // End of added.
  -	ArrayList bodyparts;  // the list of attachments
   	ListIterator iterate;  // iterator for the list of attachments
   	String to = null;  // the to address for this e-mail message
   	String cc = null;  // the cc address for this e-mail message
  @@ -144,7 +149,7 @@
   	    try {
   		// set the to address for this message
   		// catch any errors in the format of the addresses
  -	        message.setRecipients(Message.RecipientType.TO, 
  +	        message.setRecipients(Message.RecipientType.TO,
   				      InternetAddress.parse(to));
   	    } catch (AddressException ae) {
   		// get the address that the error occured with
  @@ -251,7 +256,7 @@
   	if ((cc = myparent.getCc()) != null) {
   
   	    try {
  -                message.setRecipients(Message.RecipientType.CC, 
  +                message.setRecipients(Message.RecipientType.CC,
   					   InternetAddress.parse(cc));
   	    } catch (AddressException ae) {
   		// get the address that the error occured with
  @@ -282,7 +287,7 @@
   		// exception occurs when any of the addresses cannot be
   		// properly set in the message
                   String errorinput = "Messaging Exception: Some cc address/es"
  -			                + " could not be set in the message." 
  +			                + " could not be set in the message."
   			                + me.getMessage();
   
   		error.add(errorinput);
  @@ -293,7 +298,7 @@
   	if ((bcc = myparent.getBcc()) != null) {
   
   	    try {
  -                message.setRecipients(Message.RecipientType.BCC, 
  +                message.setRecipients(Message.RecipientType.BCC,
   					  InternetAddress.parse(bcc));
   	    } catch (AddressException ae) {
   		// get the address that the error occured with
  @@ -324,7 +329,7 @@
   		// exception occurs when any of the addresses cannot be
   		// properly set in the message
                   String errorinput = "Messaging Exception: Some bcc address/es"
  -			                + " could not be set in the message." 
  +			                + " could not be set in the message."
   			                + me.getMessage();
   
   		error.add(errorinput);
  @@ -352,7 +357,7 @@
   		// create a mimebodypart for the body of the e-mail message
   		MimeBodyPart mbp = new MimeBodyPart();
   
  -		// set the content in the bodypart 
  +		// set the content in the bodypart
   		mbp.setContent(myparent.getBody(), getContentType(myparent));
   
   		// add the message as the first bodypart in the multipart object
  @@ -361,7 +366,7 @@
   		// get the list of attachments
   		iterate = myparent.getBodyParts().listIterator();
   
  -		// loop through the list of attachments and add them to the 
  +		// loop through the list of attachments and add them to the
   		// multipart object
   		while (iterate.hasNext()) {
   		    multipart.addBodyPart((MimeBodyPart) iterate.next());
  @@ -407,7 +412,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return - int telling the tag handler whether or not to evaluate the
  @@ -470,10 +475,10 @@
   
       private MimeMessage message = null;  // the message to be sent
       // used to get the servlet context for logging
  -    private javax.servlet.ServletContext sc = null; 
  -    String mailto;  // list of to address this message is being sent to 
  +    private javax.servlet.ServletContext sc = null;
  +    String mailto;  // list of to address this message is being sent to
   
  -    Mail (MimeMessage mail, javax.servlet.ServletContext servletcontext, 
  +    Mail (MimeMessage mail, javax.servlet.ServletContext servletcontext,
   	  String to) {
   	message = mail;
   	sc = servletcontext;
  @@ -495,7 +500,7 @@
   	    // Since the JSP has already finished executing this exception will
   	    // do nothing visible, however the errors should be dealt with by
   	    // the SMTP host if it is configured correctly
  -	    sc.log("Could not send the e-mail sent to " + mailto + ":  " + 
  +	    sc.log("Could not send the e-mail sent to " + mailto + ":  " +
   		   me.getMessage());
   	}
       }
  
  
  
  1.5       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ServerTag.java
  
  Index: ServerTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/ServerTag.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- ServerTag.java	3 Dec 2002 16:08:19 -0000	1.4
  +++ ServerTag.java	29 Jan 2004 07:22:22 -0000	1.5
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * ServerTag - JSP tag <b>server</b> is used for dynamically setting the mail
  @@ -93,7 +93,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.8       +13 -12    jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/SetRecipientTag.java
  
  Index: SetRecipientTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/SetRecipientTag.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- SetRecipientTag.java	3 Dec 2002 16:08:19 -0000	1.7
  +++ SetRecipientTag.java	29 Jan 2004 07:22:22 -0000	1.8
  @@ -61,15 +61,16 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.JspTagException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
  - * SetRecipientTag - JSP tag <b>setrecipient</b> is used to set any type of 
  - *                recipient to an e-mail. Two attributes are required, type and 
  - *                setress. Type may be either "to", "cc", or "bcc" and address 
  - *                should be a string representation of the recipients e-mail 
  + * SetRecipientTag - JSP tag <b>setrecipient</b> is used to set any type of
  + *                recipient to an e-mail. Two attributes are required, type and
  + *                setress. Type may be either "to", "cc", or "bcc" and address
  + *                should be a string representation of the recipients e-mail
    *                address.
    *
    * <tag>
  @@ -115,7 +116,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do at the start of this tag
        *
  -     *  @throws JSPTagException  thrown when an error occurs while processing the
  +     *  @throws JspTagException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  @@ -137,7 +138,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.7       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/SubjectTag.java
  
  Index: SubjectTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/SubjectTag.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- SubjectTag.java	3 Dec 2002 16:08:19 -0000	1.6
  +++ SubjectTag.java	29 Jan 2004 07:22:22 -0000	1.7
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * SubjectTag - JSP tag <b>Subject</b> is used to set the subject in an e-mail.
  @@ -88,7 +88,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  
  1.2       +7 -7      jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/UserTag.java
  
  Index: UserTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/mailer/src/org/apache/taglibs/mailer/UserTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- UserTag.java	11 Nov 2003 05:25:17 -0000	1.1
  +++ UserTag.java	29 Jan 2004 07:22:22 -0000	1.2
  @@ -61,9 +61,9 @@
   
   package org.apache.taglibs.mailer;
   
  -import java.util.*;
  -import javax.servlet.jsp.*;
  -import javax.servlet.jsp.tagext.*;
  +import javax.servlet.jsp.JspException;
  +import javax.servlet.jsp.tagext.BodyContent;
  +import javax.servlet.jsp.tagext.BodyTagSupport;
   
   /**
    * UserTag - JSP tag <b>User</b> is used to set the user name for authentication.
  @@ -88,7 +88,7 @@
        *  implementation of the method from the tag interface that tells the JSP
        *  page what to do after the body of this tag
        *
  -     *  @throws JSPException  thrown when an error occurs while processing the
  +     *  @throws JspException  thrown when an error occurs while processing the
        *                        body of this method
        *
        *  @return SKIP_BODY  int telling the tag handler to not evaluate the body
  
  
  

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