FileDocCategorySizeDatePackage
AptExternalCompilerAdapter.javaAPI DocApache Ant 1.702270Wed Dec 13 06:16:18 GMT 2006org.apache.tools.ant.taskdefs.compilers

AptExternalCompilerAdapter

public class AptExternalCompilerAdapter extends DefaultCompilerAdapter
The implementation of the apt compiler for JDK 1.5 using an external process
since
Ant 1.7

Fields Summary
Constructors Summary
Methods Summary
public booleanexecute()
Performs a compile using the Javac externally.

return
true the compilation was successful.
throws
BuildException if there is a problem.

        attributes.log("Using external apt compiler", Project.MSG_VERBOSE);


        // Setup the apt executable
        Apt apt = getApt();
        Commandline cmd = new Commandline();
        cmd.setExecutable(apt.getAptExecutable());
        setupModernJavacCommandlineSwitches(cmd);
        AptCompilerAdapter.setAptCommandlineSwitches(apt, cmd);
        int firstFileName = cmd.size();
        //add the files
        logAndAddFilesToCompile(cmd);

        //run
        return 0 == executeExternalCompile(cmd.getCommandline(),
                firstFileName,
                true);

    
protected org.apache.tools.ant.taskdefs.AptgetApt()
Get the facade task that fronts this adapter

return
task instance
see
DefaultCompilerAdapter#getJavac()

        return (Apt) getJavac();