/** * Return a String that describes the java command and arguments * for in-VM executions. * * <p>The class name is the executable in this context.</p> * @return the description string. * @since Ant 1.5 */ public String describeJavaCommand() { return Commandline.describeCommand(getJavaCommand()); }
/** * Executes the given classname with the given arguments as it * were a command line application. * @param command CommandlineJava. */ private void run(CommandlineJava command) throws BuildException { try { ExecuteJava exe = new ExecuteJava(); exe.setJavaCommand(command.getJavaCommand()); exe.setClasspath(command.getClasspath()); exe.setSystemProperties(command.getSystemProperties()); exe.setPermissions(perm); exe.setTimeout(timeout); redirector.createStreams(); exe.execute(getProject()); redirector.complete(); if (exe.killedProcess()) { throw new BuildException(TIMEOUT_MESSAGE); } } catch (IOException e) { throw new BuildException(e); } }
java.setClassname("org.apache.jasper.JspC"); for (String arg : cmd.getJavaCommand().getArguments()) { java.createArg().setValue(arg);
public JavaTaskBuilder withProperties(Map<String, String> properties) { if (properties != null) { for (Object key : properties.keySet()) { // javaTask.createArg() would append the parameter at the beginning before the classname // but it must be appended at the end. Commandline.Argument newArg = javaTask.getCommandLine().getJavaCommand().createArgument(false); newArg.setLine("-p " + key + "=" + properties.get(key)); } } return this; }
public JavaTaskBuilder withProgressMonitorClass(String progressMonitorClass) { if (progressMonitorClass != null) { Commandline.Argument newArg = javaTask.getCommandLine().getJavaCommand().createArgument(false); newArg.setLine("-m " + progressMonitorClass); } return this; }
if (commandLine.getJavaCommand().getArguments() != null && commandLine.getJavaCommand().getArguments().length > 0) { commandBuilder.append(" ").append( Joiner.on(' ').join(commandLine.getJavaCommand().getArguments()));
log(ToolVersion.VERSION.BUILD_VERSION); log("command line: " + tool + (getFork() ? getCommandline().getJavaCommand() : getCommandline()).toString()); Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader()); try { ok = runInVm(getCommandline().getJavaCommand().getArguments(), logstr); } finally { Thread.currentThread().setContextClassLoader(old);
log(ToolVersion.VERSION.BUILD_VERSION); log("command line: " + tool + (getFork() ? getCommandline().getJavaCommand() : getCommandline()).toString()); Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader()); try { ok = runInVm(getCommandline().getJavaCommand().getArguments(), logstr); } finally { Thread.currentThread().setContextClassLoader(old);
log(ToolVersion.VERSION.BUILD_VERSION); log("command line: " + tool + (getFork() ? getCommandline().getJavaCommand() : getCommandline()).toString()); Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader()); try { ok = runInVm(getCommandline().getJavaCommand().getArguments(), logstr); } finally { Thread.currentThread().setContextClassLoader(old);
log(ToolVersion.VERSION.BUILD_VERSION); log("command line: " + tool + (getFork() ? getCommandline().getJavaCommand() : getCommandline()).toString()); Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader()); try { ok = runInVm(getCommandline().getJavaCommand().getArguments(), logstr); } finally { Thread.currentThread().setContextClassLoader(old);
log("Command invoked: " + command.getJavaCommand().toString()); execute.setJavaCommand(command.getJavaCommand()); if (execute.fork(this) != 0) throw new BuildException("Could not invoke WSProvideTask", getLocation());
log("Command invoked: " + command.getJavaCommand().toString()); execute.setJavaCommand(command.getJavaCommand()); if (execute.fork(this) != 0) throw new BuildException("Could not invoke WSConsumeTask", getLocation());
java.setClassname("org.jboss.aop.standalone.Compiler"); String args[] = cmd.getJavaCommand().getArguments(); for (int i = 0; i < args.length; i++)
log("Command invoked: " + command.getJavaCommand().toString());
java.setClassname("org.jboss.ant.tasks.retrocheck.Checker"); String args[] = cmd.getJavaCommand().getArguments(); for (int i = 0; i < args.length; i++)
String args[] = cmd.getJavaCommand().getArguments(); for (int i = 0; i < args.length; i++)
java.setClassname("org.jboss.aop.annotation.compiler.AnnotationCompiler"); String args[] = cmd.getJavaCommand().getArguments(); for (int i = 0; i < args.length; i++)
log("Command invoked: " + command.getJavaCommand().toString());