Package org.apache.tools.ant.taskdefs

Examples of org.apache.tools.ant.taskdefs.Java.execute()


        // Start the server int a seperate thread
        Thread t = new Thread("Geronimo Server Runner") {
            public void run() {
                try {
                    java.execute();
                }
                catch (Exception e) {
                    errorHolder.set(e);

                    //
View Full Code Here


            log.info("Redirecting output to: " + file);

            java.setOutput(file);
        }

        java.execute();
    }

    private String appendSystemPath(final String name, final File file) {
        assert name != null;
        assert file != null;
View Full Code Here

                new File(binDir, "run.jar"));
            addToolsJarToClasspath(classpath);
            java.setClassname("org.jboss.Main");
            java.createArg().setValue("-c");
            java.createArg().setValue(this.config);
            java.execute();
        }
        catch (IOException ioe)
        {
            getLog().error("Failed to startup the container", ioe);
            throw new BuildException(ioe);
View Full Code Here

        else
        {
            java.createArg().setValue(this.getServer());
            java.createArg().setValue(String.valueOf(getPort()));
        }
        java.execute();
    }

    // Private Methods ---------------------------------------------------------

    /**
 
View Full Code Here

            java.createArg().setFile(new File(installDir, "resin.conf"));
   
            // Add settings specific to a given container version
            startUpAdditions(java, classpath);
           
            java.execute();
        }
        catch (IOException ioe)
        {
            getLog().error("Failed to startup the container", ioe);
            throw new BuildException(ioe);
View Full Code Here

        fileSet.setDir(getDir());
        fileSet.createInclude().setName("lib/*.jar");
        classpath.addFileset(fileSet);
        java.setClassname(ResinRun.class.getName());
        java.createArg().setValue("-stop");
        java.execute();
    }
   
    // Protected Methods -------------------------------------------------------

    /**
 
View Full Code Here

                new File(serverDir, "lib/weblogic_sp.jar"));
            classpath.createPathElement().setLocation(
                new File(serverDir, "lib/weblogic.jar"));

            java.setClassname("weblogic.Server");
            java.execute();
        }
        catch (IOException ioe)
        {
            getLog().error("Failed to startup the container", ioe);
            throw new BuildException(ioe);
View Full Code Here

        java.createArg().setValue("weblogic");
       
        // Forcing WebLogic shutdown to speed up the shutdown process
        java.createArg().setValue("FORCESHUTDOWN");

        java.execute();
    }

    // Private Methods ---------------------------------------------------------

    /**
 
View Full Code Here

            javaTask.setClasspathRef(this.classpathRef);
        }
        if (this.classpath != null) {
            javaTask.setClasspath(this.classpath);
        }
        javaTask.execute();
    }

    protected boolean isEmpty(String string) {
        return (string == null || string.trim().length() == 0);
    }
View Full Code Here

      task.setOutputproperty(outputProperty);
     
      Argument versionArgument = task.createArg();
      versionArgument.setValue("--version");
     
      task.execute();
     
      //Parse version number and return as int
      String output = project.getProperty(outputProperty);
      int prefixIndex = output.indexOf("Version ");
      int version = Integer.parseInt(output.substring(prefixIndex + 8, prefixIndex + 9));
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.