Logo Search packages:      
Sourcecode: gant version File versions

void org::codehaus::gant::ant::Gant::execute (  )  throws BuildException [inline]

Load the file and then execute it

Definition at line 65 of file Gant.java.

References file, and target.

                                                {
    if ( ! ( new File ( file ) ).exists ( ) ) { throw new BuildException ( "Gantfile does not exist." , getLocation ( ) ) ; }
    final gant.Gant gant = new gant.Gant ( file ) ;
    final int returnCode ;
    if ( target.equals ( "" ) ) { returnCode = gant.processTargets ( ) ; }
    else { returnCode = gant.processTargets ( target ) ; }
    if ( returnCode != 0 ) { throw new BuildException ( "Gant execution failed with return code " + Integer.toString ( returnCode ) + "." , getLocation ( ) ) ; }
  }


Generated by  Doxygen 1.6.0   Back to index