ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bode...@apache.org
Subject cvs commit: jakarta-ant/src/main/org/apache/tools/ant/taskdefs/email Message.java
Date Fri, 10 May 2002 13:33:33 GMT
bodewig     02/05/10 06:33:33

  Modified:    src/main/org/apache/tools/ant/taskdefs/email Tag:
                        ANT_15_BRANCH Message.java
  Log:
  Expand properties in mail messages.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.1   +6 -4      jakarta-ant/src/main/org/apache/tools/ant/taskdefs/email/Message.java
  
  Index: Message.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/email/Message.java,v
  retrieving revision 1.3
  retrieving revision 1.3.2.1
  diff -u -r1.3 -r1.3.2.1
  --- Message.java	14 Apr 2002 11:16:15 -0000	1.3
  +++ Message.java	10 May 2002 13:33:32 -0000	1.3.2.1
  @@ -53,6 +53,8 @@
    */
   package org.apache.tools.ant.taskdefs.email;
   
  +import org.apache.tools.ant.ProjectComponent;
  +
   import java.io.BufferedReader;
   import java.io.File;
   import java.io.FileReader;
  @@ -65,7 +67,7 @@
    * @author roxspring@yahoo.com Rob Oxspring
    * @since Ant 1.5
    */
  -public class Message {
  +public class Message extends ProjectComponent {
       private File messageSource = null;
       private StringBuffer buffer = new StringBuffer();
       private String mimeType = "text/plain";
  @@ -155,19 +157,19 @@
                   String line = null;
   
                   while ((line = in.readLine()) != null) {
  -                    out.println(line);
  +                    out.println(getProject().replaceProperties(line));
                   }
               } finally {
                   freader.close();
               }
           } else {
  -            out.println(buffer);
  +            out.println(getProject().replaceProperties(buffer.toString()));
           }
       }
   
   
       /**
  -     * Returns true iff the mimeType has been set.
  +     * Returns true if the mimeType has been set.
        *
        * @return false if the default value is in use
        */
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message