Browse Source

javadoc

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@277351 13f79535-47bb-0310-9956-ffa450edef68
master
Peter Reilly 20 years ago
parent
commit
3a21f4ff19
1 changed files with 25 additions and 10 deletions
  1. +25
    -10
      src/main/org/apache/tools/ant/types/CommandlineJava.java

+ 25
- 10
src/main/org/apache/tools/ant/types/CommandlineJava.java View File

@@ -81,7 +81,7 @@ public class CommandlineJava implements Cloneable {
* get the properties as an array; this is an override of the * get the properties as an array; this is an override of the
* superclass, as it evaluates all the properties * superclass, as it evaluates all the properties
* @return the array of definitions; may be null * @return the array of definitions; may be null
* @throws BuildException
* @throws BuildException on error
*/ */
public String[] getVariables() throws BuildException { public String[] getVariables() throws BuildException {


@@ -170,6 +170,7 @@ public class CommandlineJava implements Cloneable {
/** /**
* deep clone * deep clone
* @return a cloned instance of SysProperties * @return a cloned instance of SysProperties
* @exception CloneNotSupportedException for signature
*/ */
public Object clone() throws CloneNotSupportedException { public Object clone() throws CloneNotSupportedException {
try { try {
@@ -246,16 +247,16 @@ public class CommandlineJava implements Cloneable {
} }


/** /**
* set the executable used to start the new JVM
* @param vm
* Set the executable used to start the new JVM.
* @param vm the executable to use
*/ */
public void setVm(String vm) { public void setVm(String vm) {
vmCommand.setExecutable(vm); vmCommand.setExecutable(vm);
} }


/** /**
* set the JVM version required
* @param value
* Set the JVM version required.
* @param value the version required
*/ */
public void setVmversion(String value) { public void setVmversion(String value) {
vmVersion = value; vmVersion = value;
@@ -265,6 +266,7 @@ public class CommandlineJava implements Cloneable {
* If set, system properties will be copied to the cloned VM - as * If set, system properties will be copied to the cloned VM - as
* well as the bootclasspath unless you have explicitly specified * well as the bootclasspath unless you have explicitly specified
* a bootclaspath. * a bootclaspath.
* @param cloneVm if true copy the system properties
* @since Ant 1.7 * @since Ant 1.7
*/ */
public void setCloneVm(boolean cloneVm) { public void setCloneVm(boolean cloneVm) {
@@ -328,6 +330,11 @@ public class CommandlineJava implements Cloneable {
return null; return null;
} }


/**
* Create a classpath.
* @param p the project to use to create the path in
* @return a path to be configured
*/
public Path createClasspath(Project p) { public Path createClasspath(Project p) {
if (classpath == null) { if (classpath == null) {
classpath = new Path(p); classpath = new Path(p);
@@ -336,6 +343,9 @@ public class CommandlineJava implements Cloneable {
} }


/** /**
* Create a boot classpath.
* @param p the project to use to create the path in
* @return a path to be configured
* @since Ant 1.6 * @since Ant 1.6
*/ */
public Path createBootclasspath(Project p) { public Path createBootclasspath(Project p) {
@@ -345,6 +355,10 @@ public class CommandlineJava implements Cloneable {
return bootclasspath; return bootclasspath;
} }


/**
* Get the vm version.
* @return the vm version
*/
public String getVmversion() { public String getVmversion() {
return vmVersion; return vmVersion;
} }
@@ -390,7 +404,7 @@ public class CommandlineJava implements Cloneable {
if (bcp.size() > 0) { if (bcp.size() > 0) {
listIterator.add("-Xbootclasspath:" + bcp.toString()); listIterator.add("-Xbootclasspath:" + bcp.toString());
} }
//main classpath //main classpath
if (haveClasspath()) { if (haveClasspath()) {
listIterator.add("-classpath"); listIterator.add("-classpath");
@@ -418,6 +432,7 @@ public class CommandlineJava implements Cloneable {
/** /**
* Specify max memory of the JVM * Specify max memory of the JVM
* -mx or -Xmx depending on VM version * -mx or -Xmx depending on VM version
* @param max the string to pass to the jvm to specifiy the max memory
*/ */
public void setMaxmemory(String max) { public void setMaxmemory(String max) {
this.maxMemory = max; this.maxMemory = max;
@@ -436,7 +451,7 @@ public class CommandlineJava implements Cloneable {
* Returns a String that describes the command and arguments * Returns a String that describes the command and arguments
* suitable for verbose output before a call to * suitable for verbose output before a call to
* <code>Runtime.exec(String[])<code> * <code>Runtime.exec(String[])<code>
*
* @return the description string
* @since Ant 1.5 * @since Ant 1.5
*/ */
public String describeCommand() { public String describeCommand() {
@@ -448,7 +463,7 @@ public class CommandlineJava implements Cloneable {
* for in VM executions. * for in VM executions.
* *
* <p>The class name is the executable in this context.</p> * <p>The class name is the executable in this context.</p>
*
* @return the description string
* @since Ant 1.5 * @since Ant 1.5
*/ */
public String describeJavaCommand() { public String describeJavaCommand() {
@@ -599,7 +614,7 @@ public class CommandlineJava implements Cloneable {
/** /**
* Has the classpath been specified and shall it really be used or * Has the classpath been specified and shall it really be used or
* will build.sysclasspath null it? * will build.sysclasspath null it?
*
* @return true if the classpath is to be used
* @since Ant 1.6 * @since Ant 1.6
*/ */
protected boolean haveClasspath() { protected boolean haveClasspath() {
@@ -616,7 +631,7 @@ public class CommandlineJava implements Cloneable {
* *
* @param log whether to log a warning if a bootclasspath has been * @param log whether to log a warning if a bootclasspath has been
* specified but will be ignored. * specified but will be ignored.
*
* @return true if the bootclasspath is to be used
* @since Ant 1.6 * @since Ant 1.6
*/ */
protected boolean haveBootclasspath(boolean log) { protected boolean haveBootclasspath(boolean log) {


Loading…
Cancel
Save