A representation of a Java command line that is
a composite of 2 Commandlines. One is used for the
vm/options and one for the classname/arguments. It provides
specific methods for a Java command line.
Inner Class :public static class SysProperties extends Environment implements Cloneable
Constructor Summary
public
CommandlineJava() Constructor uses the VM we are running on now.
Method Summary
public void
addSysproperties(SysProperties sysp) Add a set of system properties.
haveBootclasspath(boolean log) Determine whether the bootclasspath has been specified, and whether it
shall really be used (build.sysclasspath could be set or the VM may not
support it).
Parameters: log - whether to log a warning if a bootclasspath has beenspecified but will be ignored.
protected boolean
haveClasspath() Determine whether the classpath has been specified, and whether it shall
really be used or be nulled by build.sysclasspath.
setCloneVm(boolean cloneVm) Set whether system properties will be copied to the cloned VM--as
well as the bootclasspath unless you have explicitly specified
a bootclasspath.
public void
setJar(String jarpathname) Set a jar file to execute via the -jar option.
Return a String that describes the command and arguments suitable for
verbose output before a call to Runtime.exec(String[]).
the description string. since: Ant 1.5
Get the name of the jar to be run.
the pathname of the jar file to run via -jar optionor null if there is no jar to run. See Also:CommandlineJava.getClassname()
Determine whether the bootclasspath has been specified, and whether it
shall really be used (build.sysclasspath could be set or the VM may not
support it).
Parameters: log - whether to log a warning if a bootclasspath has beenspecified but will be ignored. true if the bootclasspath is to be used. since: Ant 1.6
Determine whether the classpath has been specified, and whether it shall
really be used or be nulled by build.sysclasspath.
true if the classpath is to be used. since: Ant 1.6
Set whether system properties will be copied to the cloned VM--as
well as the bootclasspath unless you have explicitly specified
a bootclasspath.
Parameters: cloneVm - if true copy the system properties. since: Ant 1.7
Get the size of the java command line. This is a fairly intensive
operation, as it has to evaluate the size of many components.
the total number of arguments in the java command line. See Also:CommandlineJava.getCommandline()