diff --git a/src/main/org/apache/tools/ant/Project.java b/src/main/org/apache/tools/ant/Project.java
index a00f28e4b..79b6d140d 100644
--- a/src/main/org/apache/tools/ant/Project.java
+++ b/src/main/org/apache/tools/ant/Project.java
@@ -59,54 +59,54 @@ import org.apache.tools.ant.util.StringUtils;
*/
public class Project {
- /** Message priority of "error". */
+ /** Message priority of "error". */
public static final int MSG_ERR = 0;
- /** Message priority of "warning". */
+ /** Message priority of "warning". */
public static final int MSG_WARN = 1;
- /** Message priority of "information". */
+ /** Message priority of "information". */
public static final int MSG_INFO = 2;
- /** Message priority of "verbose". */
+ /** Message priority of "verbose". */
public static final int MSG_VERBOSE = 3;
- /** Message priority of "debug". */
+ /** Message priority of "debug". */
public static final int MSG_DEBUG = 4;
/**
- * Constant for the "visiting" state, used when
+ * Constant for the "visiting" state, used when
* traversing a DFS of target dependencies.
*/
private static final String VISITING = "VISITING";
/**
- * Constant for the "visited" state, used when
+ * Constant for the "visited" state, used when
* traversing a DFS of target dependencies.
*/
private static final String VISITED = "VISITED";
/**
- * Version constant for Java 1.0
+ * Version constant for Java 1.0 .
*
* @deprecated Use {@link JavaEnvUtils#JAVA_1_0} instead.
*/
public static final String JAVA_1_0 = JavaEnvUtils.JAVA_1_0;
/**
- * Version constant for Java 1.1
+ * Version constant for Java 1.1 .
*
* @deprecated Use {@link JavaEnvUtils#JAVA_1_1} instead.
*/
public static final String JAVA_1_1 = JavaEnvUtils.JAVA_1_1;
/**
- * Version constant for Java 1.2
+ * Version constant for Java 1.2 .
*
* @deprecated Use {@link JavaEnvUtils#JAVA_1_2} instead.
*/
public static final String JAVA_1_2 = JavaEnvUtils.JAVA_1_2;
/**
- * Version constant for Java 1.3
+ * Version constant for Java 1.3 .
*
* @deprecated Use {@link JavaEnvUtils#JAVA_1_3} instead.
*/
public static final String JAVA_1_3 = JavaEnvUtils.JAVA_1_3;
/**
- * Version constant for Java 1.4
+ * Version constant for Java 1.4 .
*
* @deprecated Use {@link JavaEnvUtils#JAVA_1_4} instead.
*/
@@ -156,7 +156,7 @@ public class Project {
private Vector listeners = new Vector();
/**
- * The Ant core classloader - may be null
if using
+ * The Ant core classloader--may be null
if using
* parent classloader.
*/
private ClassLoader coreLoader = null;
@@ -173,22 +173,22 @@ public class Project {
private InputHandler inputHandler = null;
/**
- * The default input stream used to read any input
+ * The default input stream used to read any input.
*/
private InputStream defaultInputStream = null;
/**
- * Keep going flag
+ * Keep going flag.
*/
private boolean keepGoingMode = false;
/**
- * Flag which catches Listeners which try to use System.out or System.err
+ * Flag which catches Listeners which try to use System.out or System.err .
*/
private boolean loggingMessage = false;
/**
- * Sets the input handler
+ * Set the input handler.
*
* @param handler the InputHandler instance to use for gathering input.
*/
@@ -210,17 +210,17 @@ public class Project {
}
/**
- * Get this project's input stream
+ * Get this project's input stream.
*
* @return the InputStream instance in use by this Project instance to
- * read input
+ * read input.
*/
public InputStream getDefaultInputStream() {
return defaultInputStream;
}
/**
- * Retrieves the current input handler.
+ * Retrieve the current input handler.
*
* @return the InputHandler instance currently in place for the project
* instance.
@@ -230,15 +230,15 @@ public class Project {
}
/**
- * Creates a new Ant project.
+ * Create a new Ant project.
*/
public Project() {
inputHandler = new DefaultInputHandler();
}
/**
- * inits a sub project - used by taskdefs.Ant
- * @param subProject the subproject to initialize
+ * Init a sub project--used by taskdefs.Ant .
+ * @param subProject the subproject to initialize.
*/
public void initSubProject(Project subProject) {
ComponentHelper.getComponentHelper(subProject)
@@ -247,12 +247,12 @@ public class Project {
}
/**
- * Initialises the project.
+ * Initialise the project.
*
* This involves setting the default task definitions and loading the
* system properties.
*
- * @exception BuildException if the default task list cannot be loaded
+ * @exception BuildException if the default task list cannot be loaded.
*/
public void init() throws BuildException {
setJavaVersionProperty();
@@ -264,11 +264,11 @@ public class Project {
/**
* Factory method to create a class loader for loading classes from
- * a given path
+ * a given path.
*
* @param path the path from which classes are to be loaded.
*
- * @return an appropriate classloader
+ * @return an appropriate classloader.
*/
public AntClassLoader createClassLoader(Path path) {
AntClassLoader loader = new AntClassLoader2();
@@ -278,7 +278,7 @@ public class Project {
}
/**
- * Sets the core classloader for the project. If a null
+ * Set the core classloader for the project. If a null
* classloader is specified, the parent classloader should be used.
*
* @param coreLoader The classloader to use for the project.
@@ -289,7 +289,7 @@ public class Project {
}
/**
- * Returns the core classloader to use for this project.
+ * Return the core classloader to use for this project.
* This may be null
, indicating that
* the parent classloader should be used.
*
@@ -301,7 +301,7 @@ public class Project {
}
/**
- * Adds a build listener to the list. This listener will
+ * Add a build listener to the list. This listener will
* be notified of build events for this project.
*
* @param listener The listener to add to the list.
@@ -316,7 +316,7 @@ public class Project {
}
/**
- * Removes a build listener from the list. This listener
+ * Remove a build listener from the list. This listener
* will no longer be notified of build events for this project.
*
* @param listener The listener to remove from the list.
@@ -331,7 +331,7 @@ public class Project {
}
/**
- * Returns a copy of the list of build listeners for the project.
+ * Return a copy of the list of build listeners for the project.
*
* @return a list of build listeners for the project
*/
@@ -340,8 +340,8 @@ public class Project {
}
/**
- * Writes a message to the log with the default log level
- * of MSG_INFO
+ * Write a message to the log with the default log level
+ * of MSG_INFO .
* @param message The text to log. Should not be null
.
*/
@@ -350,46 +350,46 @@ public class Project {
}
/**
- * Writes a project level message to the log with the given log level.
+ * Write a project level message to the log with the given log level.
* @param message The text to log. Should not be null
.
- * @param msgLevel The priority level to log at.
+ * @param msgLevel The log priority level to use.
*/
public void log(String message, int msgLevel) {
fireMessageLogged(this, message, msgLevel);
}
/**
- * Writes a task level message to the log with the given log level.
+ * Write a task level message to the log with the given log level.
* @param task The task to use in the log. Must not be null
.
* @param message The text to log. Should not be null
.
- * @param msgLevel The priority level to log at.
+ * @param msgLevel The log priority level to use.
*/
public void log(Task task, String message, int msgLevel) {
fireMessageLogged(task, message, msgLevel);
}
/**
- * Writes a target level message to the log with the given log level.
+ * Write a target level message to the log with the given log level.
* @param target The target to use in the log.
* Must not be null
.
* @param message The text to log. Should not be null
.
- * @param msgLevel The priority level to log at.
+ * @param msgLevel The log priority level to use.
*/
public void log(Target target, String message, int msgLevel) {
fireMessageLogged(target, message, msgLevel);
}
/**
- * Returns the set of global filters.
+ * Return the set of global filters.
*
- * @return the set of global filters
+ * @return the set of global filters.
*/
public FilterSet getGlobalFilterSet() {
return globalFilterSet;
}
/**
- * Sets a property. Any existing property of the same name
+ * Set a property. Any existing property of the same name
* is overwritten, unless it is a user property.
* @param name The name of property to set.
* Must not be null
.
@@ -402,7 +402,7 @@ public class Project {
}
/**
- * Sets a property if no value currently exists. If the property
+ * Set a property if no value currently exists. If the property
* exists already, a message is logged and the method returns with
* no other effect.
*
@@ -418,7 +418,7 @@ public class Project {
}
/**
- * Sets a user property, which cannot be overwritten by
+ * Set a user property, which cannot be overwritten by
* set/unset property calls. Any previous value is overwritten.
* @param name The name of property to set.
* Must not be null
.
@@ -432,7 +432,7 @@ public class Project {
}
/**
- * Sets a user property, which cannot be overwritten by set/unset
+ * Set a user property, which cannot be overwritten by set/unset
* property calls. Any previous value is overwritten. Also marks
* these properties as properties that have not come from the
* command line.
@@ -449,7 +449,7 @@ public class Project {
}
/**
- * Sets a property unless it is already defined as a user property
+ * Set a property unless it is already defined as a user property
* (in which case the method returns silently).
*
* @param name The name of the property.
@@ -462,7 +462,7 @@ public class Project {
}
/**
- * Returns the value of a property, if it is set.
+ * Return the value of a property, if it is set.
*
* @param name The name of the property.
* May be null
, in which case
@@ -476,7 +476,7 @@ public class Project {
}
/**
- * Replaces ${} style constructions in the given value with the
+ * Replace ${} style constructions in the given value with the
* string value of the corresponding data types.
*
* @param value The string to be scanned for property references.
@@ -487,7 +487,7 @@ public class Project {
* null
.
*
* @exception BuildException if the given value has an unclosed
- * property name, e.g. ${xxx
+ * property name, e.g. ${xxx
.
*/
public String replaceProperties(String value)
throws BuildException {
@@ -496,7 +496,7 @@ public class Project {
}
/**
- * Returns the value of a user property, if it is set.
+ * Return the value of a user property, if it is set.
*
* @param name The name of the property.
* May be null
, in which case
@@ -510,7 +510,7 @@ public class Project {
}
/**
- * Returns a copy of the properties table.
+ * Return a copy of the properties table.
* @return a hashtable containing all properties
* (including user properties).
*/
@@ -520,8 +520,8 @@ public class Project {
}
/**
- * Returns a copy of the user property hashtable
- * @return a hashtable containing just the user properties
+ * Return a copy of the user property hashtable.
+ * @return a hashtable containing just the user properties.
*/
public Hashtable getUserProperties() {
PropertyHelper ph = PropertyHelper.getPropertyHelper(this);
@@ -529,11 +529,11 @@ public class Project {
}
/**
- * Copies all user properties that have been set on the command
+ * Copy all user properties that have been set on the command
* line or a GUI tool from this instance to the Project instance
* given as the argument.
*
- *
To copy all "user" properties, you will also have to call + *
To copy all "user" properties, you will also have to call * {@link #copyInheritedProperties copyInheritedProperties}.
* * @param other the project to copy the properties to. Must not be null. @@ -546,11 +546,11 @@ public class Project { } /** - * Copies all user properties that have not been set on the + * Copy all user properties that have not been set on the * command line or a GUI tool from this instance to the Project * instance given as the argument. * - *To copy all "user" properties, you will also have to call + *
To copy all "user" properties, you will also have to call * {@link #copyUserProperties copyUserProperties}.
* * @param other the project to copy the properties to. Must not be null. @@ -563,7 +563,7 @@ public class Project { } /** - * Sets the default target of the project. + * Set the default target of the project. * * @param defaultTarget The name of the default target for this project. * May benull
, indicating that there is
@@ -577,7 +577,7 @@ public class Project {
}
/**
- * Returns the name of the default target of the project.
+ * Return the name of the default target of the project.
* @return name of the default target or
* null
if no default has been set.
*/
@@ -586,7 +586,7 @@ public class Project {
}
/**
- * Sets the default target of the project.
+ * Set the default target of the project.
*
* @param defaultTarget The name of the default target for this project.
* May be null
, indicating that there is
@@ -597,7 +597,7 @@ public class Project {
}
/**
- * Sets the name of the project, also setting the user
+ * Set the name of the project, also setting the user
* property ant.project.name
.
*
* @param name The name of the project.
@@ -609,7 +609,7 @@ public class Project {
}
/**
- * Returns the project name, if one has been set.
+ * Return the project name, if one has been set.
*
* @return the project name, or null
if it hasn't been set.
*/
@@ -618,7 +618,7 @@ public class Project {
}
/**
- * Sets the project description.
+ * Set the project description.
*
* @param description The description of the project.
* May be null
.
@@ -628,7 +628,7 @@ public class Project {
}
/**
- * Returns the project description, if one has been set.
+ * Return the project description, if one has been set.
*
* @return the project description, or null
if it hasn't
* been set.
@@ -637,12 +637,11 @@ public class Project {
if (description == null) {
description = Description.getDescription(this);
}
-
return description;
}
/**
- * Adds a filter to the set of global filters.
+ * Add a filter to the set of global filters.
*
* @param token The token to filter.
* Must not be null
.
@@ -657,12 +656,11 @@ public class Project {
if (token == null) {
return;
}
-
globalFilterSet.addFilter(new FilterSet.Filter(token, value));
}
/**
- * Returns a hashtable of global filters, mapping tokens to values.
+ * Return a hashtable of global filters, mapping tokens to values.
*
* @return a hashtable of global filters, mapping tokens to values
* (String to String).
@@ -678,26 +676,26 @@ public class Project {
}
/**
- * Sets the base directory for the project, checking that
+ * Set the base directory for the project, checking that
* the given filename exists and is a directory.
*
* @param baseD The project base directory.
* Must not be null
.
*
- * @exception BuildException if the directory if invalid
+ * @exception BuildException if the directory if invalid.
*/
public void setBasedir(String baseD) throws BuildException {
setBaseDir(new File(baseD));
}
/**
- * Sets the base directory for the project, checking that
+ * Set the base directory for the project, checking that
* the given file exists and is a directory.
*
* @param baseDir The project base directory.
* Must not be null
.
* @exception BuildException if the specified file doesn't exist or
- * isn't a directory
+ * isn't a directory.
*/
public void setBaseDir(File baseDir) throws BuildException {
baseDir = FILE_UTILS.normalize(baseDir.getAbsolutePath());
@@ -716,7 +714,7 @@ public class Project {
}
/**
- * Returns the base directory of the project as a file object.
+ * Return the base directory of the project as a file object.
*
* @return the project base directory, or null
if the
* base directory has not been successfully set to a valid value.
@@ -733,12 +731,12 @@ public class Project {
}
/**
- * Sets "keep-going" mode. In this mode ANT will try to execute
+ * Set "keep-going" mode. In this mode ANT will try to execute
* as many targets as possible. All targets that do not depend
* on failed target(s) will be executed. If the keepGoing settor/getter
* methods are used in conjunction with the ant.executor.class
* property, they will have no effect.
- * @param keepGoingMode "keep-going" mode
+ * @param keepGoingMode "keep-going" mode
* @since Ant 1.6
*/
public void setKeepGoingMode(boolean keepGoingMode) {
@@ -746,10 +744,10 @@ public class Project {
}
/**
- * Returns the keep-going mode. If the keepGoing settor/getter
+ * Return the keep-going mode. If the keepGoing settor/getter
* methods are used in conjunction with the ant.executor.class
* property, they will have no effect.
- * @return "keep-going" mode
+ * @return "keep-going" mode
* @since Ant 1.6
*/
public boolean isKeepGoingMode() {
@@ -757,8 +755,8 @@ public class Project {
}
/**
- * Returns the version of Java this class is running under.
- * @return the version of Java as a String, e.g. "1.1"
+ * Return the version of Java this class is running under.
+ * @return the version of Java as a String, e.g. "1.1" .
* @see org.apache.tools.ant.util.JavaEnvUtils#getJavaVersion
* @deprecated use org.apache.tools.ant.util.JavaEnvUtils instead
*/
@@ -767,12 +765,12 @@ public class Project {
}
/**
- * Sets the ant.java.version
property and tests for
+ * Set the ant.java.version
property and tests for
* unsupported JVM versions. If the version is supported,
* verbose log messages are generated to record the Java version
* and operating system name.
*
- * @exception BuildException if this Java version is not supported
+ * @exception BuildException if this Java version is not supported.
*
* @see org.apache.tools.ant.util.JavaEnvUtils#getJavaVersion
*/
@@ -784,7 +782,6 @@ public class Project {
if (JavaEnvUtils.isJavaVersion(JavaEnvUtils.JAVA_1_0)) {
throw new BuildException("Ant cannot work on Java 1.0");
}
-
log("Detected Java version: " + javaVersion + " in: "
+ System.getProperty("java.home"), MSG_VERBOSE);
@@ -792,7 +789,7 @@ public class Project {
}
/**
- * Adds all system properties which aren't already defined as
+ * Add all system properties which aren't already defined as
* user properties to the project properties.
*/
public void setSystemProperties() {
@@ -806,7 +803,7 @@ public class Project {
}
/**
- * Adds a new task definition to the project.
+ * Add a new task definition to the project.
* Attempting to override an existing definition with an
* equivalent one (i.e. with the same classname) results in
* a verbose log message. Attempting to override an existing definition
@@ -832,7 +829,7 @@ public class Project {
}
/**
- * Checks whether or not a class is suitable for serving as Ant task.
+ * Check whether or not a class is suitable for serving as Ant task.
* Ant task implementation classes must be public, concrete, and have
* a no-arg constructor.
*
@@ -876,8 +873,8 @@ public class Project {
}
/**
- * Returns the current task definition hashtable. The returned hashtable is
- * "live" and so should not be modified.
+ * Return the current task definition hashtable. The returned hashtable is
+ * "live" and so should not be modified.
*
* @return a map of from task name to implementing class
* (String to Class).
@@ -887,7 +884,7 @@ public class Project {
}
/**
- * Adds a new datatype definition.
+ * Add a new datatype definition.
* Attempting to override an existing definition with an
* equivalent one (i.e. with the same classname) results in
* a verbose log message. Attempting to override an existing definition
@@ -905,8 +902,8 @@ public class Project {
}
/**
- * Returns the current datatype definition hashtable. The returned
- * hashtable is "live" and so should not be modified.
+ * Return the current datatype definition hashtable. The returned
+ * hashtable is "live" and so should not be modified.
*
* @return a map of from datatype name to implementing class
* (String to Class).
@@ -916,7 +913,7 @@ public class Project {
}
/**
- * Adds a new target to the project.
+ * Add a new target to the project.
*
* @param target The target to be added to the project.
* Must not be null
.
@@ -930,14 +927,14 @@ public class Project {
}
/**
- * Adds a new target to the project.
+ * Add a new target to the project.
*
* @param targetName The name to use for the target.
* Must not be null
.
* @param target The target to be added to the project.
* Must not be null
.
*
- * @exception BuildException if the target already exists in the project
+ * @exception BuildException if the target already exists in the project.
*
* @see Project#addOrReplaceTarget
*/
@@ -950,7 +947,7 @@ public class Project {
}
/**
- * Adds a target to the project, or replaces one with the same
+ * Add a target to the project, or replaces one with the same
* name.
*
* @param target The target to be added or replaced in the project.
@@ -961,7 +958,7 @@ public class Project {
}
/**
- * Adds a target to the project, or replaces one with the same
+ * Add a target to the project, or replaces one with the same
* name.
*
* @param targetName The name to use for the target.
@@ -977,8 +974,8 @@ public class Project {
}
/**
- * Returns the hashtable of targets. The returned hashtable
- * is "live" and so should not be modified.
+ * Return the hashtable of targets. The returned hashtable
+ * is "live" and so should not be modified.
* @return a map from name to target (String to Target).
*/
public Hashtable getTargets() {
@@ -986,7 +983,7 @@ public class Project {
}
/**
- * Creates a new instance of a task, adding it to a list of
+ * Create a new instance of a task, adding it to a list of
* created tasks for later invalidation. This causes all tasks
* to be remembered until the containing project is removed
* @param taskType The name of the task to create an instance of.
@@ -1003,7 +1000,7 @@ public class Project {
}
/**
- * Creates a new instance of a data type.
+ * Create a new instance of a data type.
*
* @param typeName The name of the data type to create an instance of.
* Must not be null
.
@@ -1025,7 +1022,7 @@ public class Project {
* @param targetNames A vector of target name strings to execute.
* Must not be null
.
*
- * @exception BuildException if the build failed
+ * @exception BuildException if the build failed.
*/
public void executeTargets(Vector targetNames) throws BuildException {
@@ -1054,7 +1051,6 @@ public class Project {
addReference("ant.executor", o);
}
}
-
if (o == null) {
throw new BuildException("Unable to obtain a Target Executor instance.");
} else {
@@ -1065,7 +1061,7 @@ public class Project {
}
/**
- * Demultiplexes output so that each task receives the appropriate
+ * Demultiplex output so that each task receives the appropriate
* messages. If the current thread is not currently executing a task,
* the message is logged directly.
*
@@ -1092,11 +1088,11 @@ public class Project {
*
* @param buffer the buffer into which data is to be read.
* @param offset the offset into the buffer at which data is stored.
- * @param length the amount of data to read
+ * @param length the amount of data to read.
*
- * @return the number of bytes read
+ * @return the number of bytes read.
*
- * @exception IOException if the data cannot be read
+ * @exception IOException if the data cannot be read.
* @since Ant 1.6
*/
public int defaultInput(byte[] buffer, int offset, int length)
@@ -1114,11 +1110,11 @@ public class Project {
*
* @param buffer the buffer into which data is to be read.
* @param offset the offset into the buffer at which data is stored.
- * @param length the amount of data to read
+ * @param length the amount of data to read.
*
- * @return the number of bytes read
+ * @return the number of bytes read.
*
- * @exception IOException if the data cannot be read
+ * @exception IOException if the data cannot be read.
* @since Ant 1.6
*/
public int demuxInput(byte[] buffer, int offset, int length)
@@ -1132,7 +1128,7 @@ public class Project {
}
/**
- * Demultiplexes flush operation so that each task receives the appropriate
+ * Demultiplex flush operations so that each task receives the appropriate
* messages. If the current thread is not currently executing a task,
* the message is logged directly.
*
@@ -1155,15 +1151,13 @@ public class Project {
}
}
-
-
/**
- * Executes the specified target and any targets it depends on.
+ * Execute the specified target and any targets it depends on.
*
* @param targetName The name of the target to execute.
* Must not be null
.
*
- * @exception BuildException if the build failed
+ * @exception BuildException if the build failed.
*/
public void executeTarget(String targetName) throws BuildException {
@@ -1183,7 +1177,7 @@ public class Project {
}
/**
- * Executes a Vector
of sorted targets.
+ * Execute a Vector
of sorted targets.
* @param sortedTargets the aforementioned Vector
.
* @throws BuildException on error.
*/
@@ -1253,7 +1247,7 @@ public class Project {
}
/**
- * Returns the canonical form of a filename.
+ * Return the canonical form of a filename.
*
* If the specified file name is relative it is resolved
* with respect to the given root directory.
@@ -1261,8 +1255,8 @@ public class Project {
* @param fileName The name of the file to resolve.
* Must not be null
.
*
- * @param rootDir The directory to resolve relative file names with
- * respect to. May be null
, in which case
+ * @param rootDir The directory respective to which relative file names
+ * are resolved. May be null
, in which case
* the current directory is used.
*
* @return the resolved File.
@@ -1274,7 +1268,7 @@ public class Project {
}
/**
- * Returns the canonical form of a filename.
+ * Return the canonical form of a filename.
*
* If the specified file name is relative it is resolved * with respect to the project's base directory. @@ -1290,7 +1284,7 @@ public class Project { } /** - * Translates a path into its native (platform specific) format. + * Translate a path into its native (platform specific) format. *
* This method uses PathTokenizer to separate the input path
* into its components. This handles DOS style paths in a relatively
@@ -1309,7 +1303,6 @@ public class Project {
if (toProcess == null || toProcess.length() == 0) {
return "";
}
-
StringBuffer path = new StringBuffer(toProcess.length() + 50);
PathTokenizer tokenizer = new PathTokenizer(toProcess);
while (tokenizer.hasMoreTokens()) {
@@ -1321,7 +1314,6 @@ public class Project {
}
path.append(pathComponent);
}
-
return path.toString();
}
@@ -1334,7 +1326,7 @@ public class Project {
* @param destFile Name of file to copy to.
* Must not be null
.
*
- * @exception IOException if the copying fails
+ * @exception IOException if the copying fails.
*
* @deprecated
*/
@@ -1354,7 +1346,7 @@ public class Project {
* @param filtering Whether or not token filtering should be used during
* the copy.
*
- * @exception IOException if the copying fails
+ * @exception IOException if the copying fails.
*
* @deprecated
*/
@@ -1378,7 +1370,7 @@ public class Project {
* @param overwrite Whether or not the destination file should be
* overwritten if it already exists.
*
- * @exception IOException if the copying fails
+ * @exception IOException if the copying fails.
*
* @deprecated
*/
@@ -1407,7 +1399,7 @@ public class Project {
* the resulting file should be set to that
* of the source file.
*
- * @exception IOException if the copying fails
+ * @exception IOException if the copying fails.
*
* @deprecated
*/
@@ -1427,7 +1419,7 @@ public class Project {
* @param destFile File to copy to.
* Must not be null
.
*
- * @exception IOException if the copying fails
+ * @exception IOException if the copying fails.
*
* @deprecated
*/
@@ -1446,7 +1438,7 @@ public class Project {
* @param filtering Whether or not token filtering should be used during
* the copy.
*
- * @exception IOException if the copying fails
+ * @exception IOException if the copying fails.
*
* @deprecated
*/
@@ -1511,7 +1503,7 @@ public class Project {
}
/**
- * Calls File.setLastModified(long time) on Java above 1.1, and logs
+ * Call File.setLastModified(long time) on Java above 1.1, and logs
* a warning on Java 1.1.
*
* @param file The file to set the last modified time on.
@@ -1532,7 +1524,7 @@ public class Project {
}
/**
- * Returns the boolean equivalent of a string, which is considered
+ * Return the boolean equivalent of a string, which is considered
* true
if either "on"
, "true"
,
* or "yes"
is found, ignoring case.
*
@@ -1549,7 +1541,7 @@ public class Project {
}
/**
- * Topologically sorts a set of targets. Equivalent to calling
+ * Topologically sort a set of targets. Equivalent to calling
* topoSort(new String[] {root}, targets, true)
.
*
* @param root The name of the root target. The sort is created in such
@@ -1568,7 +1560,7 @@ public class Project {
}
/**
- * Topologically sorts a set of targets. Equivalent to calling
+ * Topologically sort a set of targets. Equivalent to calling
* topoSort(new String[] {root}, targets, returnAll)
.
*
* @param root The name of the root target. The sort is created in such
@@ -1590,7 +1582,7 @@ public class Project {
}
/**
- * Topologically sorts a set of targets.
+ * Topologically sort a set of targets.
*
* @param root String[]
containing the names of the root targets.
* The sort is created in such a way that the ordered sequence of
@@ -1653,23 +1645,24 @@ public class Project {
}
/**
- * Performs a single step in a recursive depth-first-search traversal of
+ * Perform a single step in a recursive depth-first-search traversal of
* the target dependency tree.
*
- * The current target is first set to the "visiting" state, and pushed - * onto the "visiting" stack. + * The current target is first set to the "visiting" state, and + * pushed onto the "visiting" stack. *
* An exception is then thrown if any child of the current node is in the * visiting state, as that implies a circular dependency. The exception - * contains details of the cycle, using elements of the "visiting" stack. + * contains details of the cycle, using elements of the "visiting" + * stack. *
- * If any child has not already been "visited", this method is called - * recursively on it. + * If any child has not already been "visited", this method is + * called recursively on it. *
* The current target is then added to the ordered list of targets. Note * that this is performed after the children have been visited in order - * to get the correct order. The current target is set to the "visited" - * state. + * to get the correct order. The current target is set to the + * "visited" state. *
* By the time this method returns, the ordered list contains the sequence
* of targets up to and including the current target.
@@ -1678,10 +1671,9 @@ public class Project {
* Must not be null
.
* @param targets A mapping from names to targets (String to Target).
* Must not be null
.
- * @param state A mapping from target names to states
- * (String to String).
- * The states in question are "VISITING" and "VISITED".
- * Must not be null
.
+ * @param state A mapping from target names to states (String to String).
+ * The states in question are "VISITING" and
+ * "VISITED". Must not be null
.
* @param visiting A stack of targets which are currently being visited.
* Must not be null
.
* @param ret The list to add target names to. This will end up
@@ -1713,10 +1705,8 @@ public class Project {
sb.append(parent);
sb.append("'.");
}
-
throw new BuildException(new String(sb));
}
-
for (Enumeration en = target.getDependencies(); en.hasMoreElements();) {
String cur = (String) en.nextElement();
String m = (String) state.get(cur);
@@ -1728,7 +1718,6 @@ public class Project {
throw makeCircularException(cur, visiting);
}
}
-
String p = (String) visiting.pop();
if (root != p) {
throw new RuntimeException("Unexpected internal error: expected to "
@@ -1739,7 +1728,7 @@ public class Project {
}
/**
- * Builds an appropriate exception detailing a specified circular
+ * Build an appropriate exception detailing a specified circular
* dependency.
*
* @param end The dependency to stop at. Must not be null
.
@@ -1760,7 +1749,7 @@ public class Project {
}
/**
- * Adds a reference to the project.
+ * Add a reference to the project.
*
* @param name The name of the reference. Must not be null
.
* @param value The value of the reference. Must not be null
.
@@ -1782,8 +1771,8 @@ public class Project {
}
/**
- * Returns a map of the references in the project (String to Object).
- * The returned hashtable is "live" and so must not be modified.
+ * Return a map of the references in the project (String to Object).
+ * The returned hashtable is "live" and so must not be modified.
*
* @return a map of the references in the project (String to Object).
*/
@@ -1792,7 +1781,7 @@ public class Project {
}
/**
- * Looks up a reference by its key (ID).
+ * Look up a reference by its key (ID).
*
* @param key The key for the desired reference.
* Must not be null
.
@@ -1805,7 +1794,7 @@ public class Project {
}
/**
- * Returns a description of the type of the given element, with
+ * Return a description of the type of the given element, with
* special handling for instances of tasks and data types.
*
* This is useful for logging purposes.
@@ -1813,7 +1802,7 @@ public class Project {
* @param element The element to describe.
* Must not be null
.
*
- * @return a description of the element type
+ * @return a description of the element type.
*
* @since 1.95, Ant 1.5
*/
@@ -1822,7 +1811,8 @@ public class Project {
}
/**
- * Sends a "build started" event to the build listeners for this project.
+ * Send a "build started" event
+ * to the build listeners for this project.
*/
public void fireBuildStarted() {
BuildEvent event = new BuildEvent(this);
@@ -1834,7 +1824,8 @@ public class Project {
}
/**
- * Sends a "build finished" event to the build listeners for this project.
+ * Send a "build finished" event to the build listeners
+ * for this project.
* @param exception an exception indicating a reason for a build
* failure. May be null
, indicating
* a successful build.
@@ -1850,7 +1841,7 @@ public class Project {
}
/**
- * Sends a "subbuild started" event to the build listeners for
+ * Send a "subbuild started" event to the build listeners for
* this project.
*
* @since Ant 1.6.2
@@ -1867,7 +1858,7 @@ public class Project {
}
/**
- * Sends a "subbuild finished" event to the build listeners for
+ * Send a "subbuild finished" event to the build listeners for
* this project.
* @param exception an exception indicating a reason for a build
* failure. May be null
, indicating
@@ -1888,7 +1879,8 @@ public class Project {
}
/**
- * Sends a "target started" event to the build listeners for this project.
+ * Send a "target started" event to the build listeners
+ * for this project.
*
* @param target The target which is starting to build.
* Must not be null
.
@@ -1903,8 +1895,8 @@ public class Project {
}
/**
- * Sends a "target finished" event to the build listeners for this
- * project.
+ * Send a "target finished" event to the build listeners
+ * for this project.
*
* @param target The target which has finished building.
* Must not be null
.
@@ -1923,7 +1915,8 @@ public class Project {
}
/**
- * Sends a "task started" event to the build listeners for this project.
+ * Send a "task started" event to the build listeners
+ * for this project.
*
* @param task The target which is starting to execute.
* Must not be null
.
@@ -1940,7 +1933,7 @@ public class Project {
}
/**
- * Sends a "task finished" event to the build listeners for this
+ * Send a "task finished" event to the build listeners for this
* project.
*
* @param task The task which has finished executing.
@@ -1963,7 +1956,8 @@ public class Project {
}
/**
- * Sends a "message logged" event to the build listeners for this project.
+ * Send a "message logged" event to the build listeners
+ * for this project.
*
* @param event The event to send. This should be built up with the
* appropriate task/target/project by the caller, so that
@@ -2012,8 +2006,8 @@ public class Project {
}
/**
- * Sends a "message logged" project level event to the build listeners for
- * this project.
+ * Send a "message logged" project level event
+ * to the build listeners for this project.
*
* @param project The project generating the event.
* Should not be null
.
@@ -2027,8 +2021,8 @@ public class Project {
}
/**
- * Sends a "message logged" target level event to the build listeners for
- * this project.
+ * Send a "message logged" target level event
+ * to the build listeners for this project.
*
* @param target The target generating the event.
* Must not be null
.
@@ -2042,8 +2036,8 @@ public class Project {
}
/**
- * Sends a "message logged" task level event to the build listeners for
- * this project.
+ * Send a "message logged" task level event
+ * to the build listeners for this project.
*
* @param task The task generating the event.
* Must not be null
.
@@ -2074,7 +2068,7 @@ public class Project {
}
/**
- * Get the current task associated with a thread, if any
+ * Get the current task associated with a thread, if any.
*
* @param thread the thread for which the task is required.
* @return the task which is currently registered for the given thread or
@@ -2105,10 +2099,10 @@ public class Project {
/** Returns the unmodified original object.
* This method should be called internally to
- * get the 'real' object.
+ * get the "real" object.
* The normal get method will do the replacement
- * of UnknownElement ( this is similar with the JDNI
- * refs behavior )
+ * of UnknownElement (this is similar with the JDNI
+ * refs behavior).
*/
public Object getReal(Object key) {
return super.get(key);
@@ -2116,14 +2110,14 @@ public class Project {
/** Get method for the reference table.
* It can be used to hook dynamic references and to modify
- * some references on the fly - for example for delayed
+ * some references on the fly--for example for delayed
* evaluation.
*
* It is important to make sure that the processing that is
* done inside is not calling get indirectly.
*
- * @param key
- * @return
+ * @param key lookup key.
+ * @return mapped value.
*/
public Object get(Object key) {
//System.out.println("AntRefTable.get " + key);
@@ -2141,8 +2135,8 @@ public class Project {
/**
* Set a reference to this Project on the parameterized object.
* Need to set the project before other set/add elements
- * are called
- * @param obj the object to invoke setProject(this) on
+ * are called.
+ * @param obj the object to invoke setProject(this) on.
*/
public final void setProjectReference(final Object obj) {
if (obj instanceof ProjectComponent) {