Use a precompiler with Java : Compile « Ant « Java






Use a precompiler with Java

  

Your Java code:
//@START@//
    your code
//@END@//



   <target name="compileprod">
    <copy todir="out">
        <filterchain>
            <tokenfilter>
                <replacestring from="//@START@//" to="/*" />
                <replacestring from="//@END@//" to="*/" />
            </tokenfilter>
        </filterchain>
        <fileset dir=".">
          <include name="**/*.java" />
       </fileset>
    </copy>
   </target>

   
    
  








Related examples in the same category

1.Compile the web application
2.Ant target:compile
3.Compile the stand-alone application
4.Indicate the init and max memory when compiling
5.Ant Javac setting
6.Ant javac includes
7.Javac include and exclude
8.Javac with classpath
9.Javac with encoding
10.Javac with optimize
11.Set debug and optimize for javac
12.Set failonerror for javac
13.Set debuglevel for javac
14.Set link for Javac
15.Set source version in javac
16.Set target for javac
17.Ant compile from src folder to build folder, set the class path and java files include