Examples of JApplication


Examples of org.objectstyle.woproject.ant.JApplication

   */
  protected ArrayList excludes;

  public void execute() throws MojoExecutionException, MojoFailureException {

    JApplication task = new JApplication();

    // TODO, andrus, 9/28/2006 - hook up maven loggers to the Ant project.
    task.setProject(new Project());

    task.setName(name);
    task.setMainClass(mainClass);
    task.setDestDir(destDir);
    task.setOs(os);
    task.setLongName(longName);
    task.setIcon(icon);
    task.setJvm(jvm);
    task.setJvmOptions(jvmOptions);
    task.setVersion(version);

    ArtifactMatchPattern includesMatcher = new ArtifactMatchPattern(includes);
    ArtifactMatchPattern excludesMatcher = new ArtifactMatchPattern(excludes);

    Iterator it = project.getCompileArtifacts().iterator();
    while (it.hasNext()) {
      Artifact a = (Artifact) it.next();
      addArtifact(task, a, includesMatcher, excludesMatcher);
    }

    // add main project artifact
    addArtifact(task, project.getArtifact(), includesMatcher, excludesMatcher);

    try {
      task.execute();
    } catch (BuildException e) {
      throw new MojoExecutionException("Failed to build application " + name, e);
    }
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.