ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dona...@apache.org
Subject cvs commit: jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional StyleBook.java
Date Sat, 29 Sep 2001 03:45:57 GMT
donaldp     01/09/28 20:45:57

  Modified:    src/main/org/apache/tools/ant/taskdefs/optional
                        StyleBook.java
  Log:
  Added the ability to set the loader-file as a parameter
  
  Submitted by: Marcus Börger <Marcus.Boerger@post.rwth-aachen.de>
  
  Revision  Changes    Path
  1.3       +33 -25    jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/StyleBook.java
  
  Index: StyleBook.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/StyleBook.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- StyleBook.java	2001/01/03 14:18:35	1.2
  +++ StyleBook.java	2001/09/29 03:45:56	1.3
  @@ -53,23 +53,25 @@
    */
   package org.apache.tools.ant.taskdefs.optional;
   
  -import java.io.File; 
  -import org.apache.tools.ant.BuildException; 
  -import org.apache.tools.ant.types.CommandlineJava; 
  -import org.apache.tools.ant.types.Path; 
  -import org.apache.tools.ant.Task; 
  -import org.apache.tools.ant.taskdefs.Java; 
  +import java.io.File;
  +import org.apache.tools.ant.BuildException;
  +import org.apache.tools.ant.types.CommandlineJava;
  +import org.apache.tools.ant.types.Path;
  +import org.apache.tools.ant.Task;
  +import org.apache.tools.ant.taskdefs.Java;
   
  -/** 
  +/**
    * Basic task for apache stylebook.
  - * 
  - * @author <a href="mailto:donaldp@apache.org">Peter Donald</a> 
  - */ 
  -public class StyleBook 
  -    extends Java 
  -{ 
  + *
  + * @author <a href="mailto:donaldp@apache.org">Peter Donald</a>
  + * @author <a href="mailto:marcus.boerger@post.rwth-aachen.de">Marcus B&ouml;rger</a>
  + */
  +public class StyleBook
  +    extends Java
  +{
       protected File                   m_targetDirectory;
       protected File                   m_skinDirectory;
  +    protected String                 m_loaderConfig;
       protected File                   m_book;
   
       public StyleBook() {
  @@ -80,19 +82,23 @@
   
       public void setBook( final File book ) {
           m_book = book;
  -    } 
  - 
  +    }
  +
       public void setSkinDirectory( final File skinDirectory ) {
           m_skinDirectory = skinDirectory;
  -    } 
  +    }
   
       public void setTargetDirectory( final File targetDirectory ) {
           m_targetDirectory = targetDirectory;
  -    } 
  -    
  -    public void execute()  
  -        throws BuildException  { 
  +    }
  +
  +    public void setLoaderConfig( final String loaderConfig ) {
  +        m_loaderConfig = loaderConfig;
  +    }
   
  +    public void execute()
  +        throws BuildException  {
  +
           if( null == m_targetDirectory ) {
               throw new BuildException( "TargetDirectory attribute not set." );
           }
  @@ -103,14 +109,16 @@
   
           if( null == m_book ) {
               throw new BuildException( "book attribute not set." );
  -        } 
  +        }
   
           createArg().setValue( "targetDirectory=" + m_targetDirectory );
           createArg().setValue( m_book.toString() );
           createArg().setValue( m_skinDirectory.toString() );
  +        if( null != m_loaderConfig ) {
  +          createArg().setValue( "loaderConfig=" + m_loaderConfig );
  +        }
   
           super.execute();
  -    } 
  -} 
  - 
  - 
  +    }
  +}
  +
  
  
  

Mime
View raw message