Browse Source

JavaDoc fixes (for Java8 doclint) - first bunch

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@1586262 13f79535-47bb-0310-9956-ffa450edef68
master
Jan Materne 11 years ago
parent
commit
bed22b00f7
43 changed files with 266 additions and 241 deletions
  1. +9
    -8
      src/main/org/apache/tools/ant/AntTypeDefinition.java
  2. +1
    -1
      src/main/org/apache/tools/ant/ArgumentProcessor.java
  3. +4
    -2
      src/main/org/apache/tools/ant/DirectoryScanner.java
  4. +1
    -1
      src/main/org/apache/tools/ant/Executor.java
  5. +6
    -6
      src/main/org/apache/tools/ant/IntrospectionHelper.java
  6. +2
    -2
      src/main/org/apache/tools/ant/ProjectHelper.java
  7. +1
    -1
      src/main/org/apache/tools/ant/PropertyHelper.java
  8. +2
    -2
      src/main/org/apache/tools/ant/dispatch/DispatchTask.java
  9. +9
    -8
      src/main/org/apache/tools/ant/filters/ConcatFilter.java
  10. +4
    -4
      src/main/org/apache/tools/ant/filters/TokenFilter.java
  11. +43
    -39
      src/main/org/apache/tools/ant/listener/AnsiColorLogger.java
  12. +7
    -6
      src/main/org/apache/tools/ant/taskdefs/Ant.java
  13. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Apt.java
  14. +4
    -5
      src/main/org/apache/tools/ant/taskdefs/Componentdef.java
  15. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Concat.java
  16. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Copy.java
  17. +2
    -2
      src/main/org/apache/tools/ant/taskdefs/Definer.java
  18. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Exit.java
  19. +4
    -8
      src/main/org/apache/tools/ant/taskdefs/JDBCTask.java
  20. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Javac.java
  21. +3
    -3
      src/main/org/apache/tools/ant/taskdefs/Javadoc.java
  22. +5
    -5
      src/main/org/apache/tools/ant/taskdefs/MakeUrl.java
  23. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Patch.java
  24. +3
    -5
      src/main/org/apache/tools/ant/taskdefs/Property.java
  25. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Redirector.java
  26. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Replace.java
  27. +2
    -2
      src/main/org/apache/tools/ant/taskdefs/Retry.java
  28. +7
    -2
      src/main/org/apache/tools/ant/taskdefs/Rmic.java
  29. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/SQLExec.java
  30. +5
    -5
      src/main/org/apache/tools/ant/taskdefs/SignJar.java
  31. +6
    -6
      src/main/org/apache/tools/ant/taskdefs/Sleep.java
  32. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/Tar.java
  33. +3
    -4
      src/main/org/apache/tools/ant/taskdefs/Taskdef.java
  34. +5
    -2
      src/main/org/apache/tools/ant/taskdefs/War.java
  35. +11
    -13
      src/main/org/apache/tools/ant/taskdefs/compilers/AptCompilerAdapter.java
  36. +14
    -14
      src/main/org/apache/tools/ant/taskdefs/condition/IsReachable.java
  37. +2
    -2
      src/main/org/apache/tools/ant/taskdefs/condition/Os.java
  38. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/cvslib/ChangeLogTask.java
  39. +7
    -7
      src/main/org/apache/tools/ant/taskdefs/email/EmailAddress.java
  40. +69
    -53
      src/main/org/apache/tools/ant/taskdefs/optional/PropertyFile.java
  41. +5
    -3
      src/main/org/apache/tools/ant/taskdefs/optional/ReplaceRegExp.java
  42. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/optional/XMLValidateTask.java
  43. +8
    -8
      src/main/org/apache/tools/ant/taskdefs/optional/clearcase/CCCheckin.java

+ 9
- 8
src/main/org/apache/tools/ant/AntTypeDefinition.java View File

@@ -43,15 +43,15 @@ public class AntTypeDefinition {
/** /**
* Set the restrict attribute. * Set the restrict attribute.
* @param restrict the value to set. * @param restrict the value to set.
*/
public void setRestrict(boolean restrict) {
*/
public void setRestrict(boolean restrict) {
this.restrict = restrict; this.restrict = restrict;
}
}


/** /**
* Get the restrict attribute. * Get the restrict attribute.
* @return the restrict attribute.
*/
* @return the restrict attribute.
*/
public boolean isRestrict() { public boolean isRestrict() {
return restrict; return restrict;
} }
@@ -236,12 +236,12 @@ public class AntTypeDefinition {


/** /**
* Checks if the attributes are correct. * Checks if the attributes are correct.
* <dl>
* <ul>
* <li>if the class can be created.</li> * <li>if the class can be created.</li>
* <li>if an adapter class can be created</li> * <li>if an adapter class can be created</li>
* <li>if the type is assignable from adapter</li> * <li>if the type is assignable from adapter</li>
* <li>if the type can be used with the adapter class</li> * <li>if the type can be used with the adapter class</li>
* </dl>
* </ul>
* @param project the current project. * @param project the current project.
*/ */
public void checkClass(Project project) { public void checkClass(Project project) {
@@ -298,7 +298,8 @@ public class AntTypeDefinition {


/** /**
* Inner implementation of the {@link #createAndSet(Project, Class)} logic, with no * Inner implementation of the {@link #createAndSet(Project, Class)} logic, with no
* exception catching
* exception catching.
* @param <T> return type of the method
* @param newclass class to create * @param newclass class to create
* @param project the project to use * @param project the project to use
* @return a newly constructed and bound instance. * @return a newly constructed and bound instance.


+ 1
- 1
src/main/org/apache/tools/ant/ArgumentProcessor.java View File

@@ -65,7 +65,7 @@ public interface ArgumentProcessor {
/** /**
* Print the usage of the supported arguments * Print the usage of the supported arguments
* *
* @see org.apache.tools.ant.Main.printUsage()
* @see org.apache.tools.ant.Main#printUsage()
*/ */
void printUsage(PrintStream writer); void printUsage(PrintStream writer);




+ 4
- 2
src/main/org/apache/tools/ant/DirectoryScanner.java View File

@@ -119,12 +119,12 @@ import org.apache.tools.ant.util.VectorSet;
* *
* System.out.println("FILES:"); * System.out.println("FILES:");
* String[] files = ds.getIncludedFiles(); * String[] files = ds.getIncludedFiles();
* for (int i = 0; i < files.length; i++) {
* for (int i = 0; i &lt; files.length; i++) {
* System.out.println(files[i]); * System.out.println(files[i]);
* } * }
* </pre> * </pre>
* This will scan a directory called test for .class files, but excludes all * This will scan a directory called test for .class files, but excludes all
* files in all proper subdirectories of a directory called "modules"
* files in all proper subdirectories of a directory called "modules".
* *
*/ */
public class DirectoryScanner public class DirectoryScanner
@@ -1736,7 +1736,9 @@ public class DirectoryScanner
* but would have been followed had followsymlinks been true or * but would have been followed had followsymlinks been true or
* maxLevelsOfSymlinks been bigger. * maxLevelsOfSymlinks been bigger.
* *
* @return sorted array of not followed symlinks
* @since Ant 1.8.0 * @since Ant 1.8.0
* @see #notFollowedSymlinks
*/ */
public synchronized String[] getNotFollowedSymlinks() { public synchronized String[] getNotFollowedSymlinks() {
String[] links; String[] links;


+ 1
- 1
src/main/org/apache/tools/ant/Executor.java View File

@@ -37,7 +37,7 @@ public interface Executor {
* Get the appropriate subproject Executor instance. * Get the appropriate subproject Executor instance.
* *
* This allows the top executor to control what type of executor is used to execute * This allows the top executor to control what type of executor is used to execute
* subprojects via <ant>/<antcall>/<subant> and task that extend these.
* subprojects via &lt;ant&gt;/&lt;antcall&gt;/&lt;subant&gt; and task that extend these.
* All bundled Executors return a SingleCheckExecutor (running a merged set of * All bundled Executors return a SingleCheckExecutor (running a merged set of
* depended targets for all targets called) to run sub-builds. * depended targets for all targets called) to run sub-builds.
* *


+ 6
- 6
src/main/org/apache/tools/ant/IntrospectionHelper.java View File

@@ -648,8 +648,8 @@ public final class IntrospectionHelper {
* Indicates whether the introspected class is a dynamic one, * Indicates whether the introspected class is a dynamic one,
* supporting arbitrary nested elements and/or attributes. * supporting arbitrary nested elements and/or attributes.
* *
* @return <code>true<code> if the introspected class is dynamic;
* <code>false<code> otherwise.
* @return <div><code>true</code> if the introspected class is dynamic;
* <code>false</code> otherwise.</div>
* @since Ant 1.6.3 * @since Ant 1.6.3
* *
* @see DynamicElement * @see DynamicElement
@@ -664,8 +664,8 @@ public final class IntrospectionHelper {
* Indicates whether the introspected class is a task container, * Indicates whether the introspected class is a task container,
* supporting arbitrary nested tasks/types. * supporting arbitrary nested tasks/types.
* *
* @return <code>true<code> if the introspected class is a container;
* <code>false<code> otherwise.
* @return <code>true</code> if the introspected class is a container;
* <code>false</code> otherwise.
* @since Ant 1.6.3 * @since Ant 1.6.3
* *
* @see TaskContainer * @see TaskContainer
@@ -984,13 +984,13 @@ public final class IntrospectionHelper {
* Returns a read-only list of extension points supported * Returns a read-only list of extension points supported
* by the introspected class. * by the introspected class.
* <p> * <p>
* A task/type or nested element with void methods named <code>add()<code>
* A task/type or nested element with void methods named <code>add()</code>
* or <code>addConfigured()</code>, taking a single class or interface * or <code>addConfigured()</code>, taking a single class or interface
* argument, supports extensions point. This method returns the list of * argument, supports extensions point. This method returns the list of
* all these <em>void add[Configured](type)</em> methods. * all these <em>void add[Configured](type)</em> methods.
* *
* @return a list of void, single argument add() or addConfigured() * @return a list of void, single argument add() or addConfigured()
* <code>Method<code>s of all supported extension points.
* <code>Method</code>s of all supported extension points.
* These methods are sorted such that if the argument type of a * These methods are sorted such that if the argument type of a
* method derives from another type also an argument of a method * method derives from another type also an argument of a method
* of this list, the method with the most derived argument will * of this list, the method with the most derived argument will


+ 2
- 2
src/main/org/apache/tools/ant/ProjectHelper.java View File

@@ -48,7 +48,7 @@ public class ProjectHelper {
* */ * */
public static final String ANT_ATTRIBUTE_URI = "ant:attribute"; public static final String ANT_ATTRIBUTE_URI = "ant:attribute";


/** The URI for defined types/tasks - the format is antlib:<package> */
/** The URI for defined types/tasks - the format is antlib:&lt;package&gt; */
public static final String ANTLIB_URI = "antlib:"; public static final String ANTLIB_URI = "antlib:";


/** Polymorphic attribute */ /** Polymorphic attribute */
@@ -296,7 +296,7 @@ public class ProjectHelper {
} }


/** /**
* JDK1.1 compatible access to the context class loader. Cut & paste from JAXP.
* JDK1.1 compatible access to the context class loader. Cut &amp; paste from JAXP.
* *
* @deprecated since 1.6.x. * @deprecated since 1.6.x.
* Use LoaderUtils.getContextClassLoader() * Use LoaderUtils.getContextClassLoader()


+ 1
- 1
src/main/org/apache/tools/ant/PropertyHelper.java View File

@@ -1125,7 +1125,7 @@ public class PropertyHelper implements GetProperty {
/** /**
* Get all Delegate interfaces (excluding Delegate itself) from the specified Delegate. * Get all Delegate interfaces (excluding Delegate itself) from the specified Delegate.
* @param d the Delegate to inspect. * @param d the Delegate to inspect.
* @return Set<Class>
* @return Set&lt;Class&gt;
* @since Ant 1.8.0 * @since Ant 1.8.0
*/ */
protected static Set<Class<? extends Delegate>> getDelegateInterfaces(Delegate d) { protected static Set<Class<? extends Delegate>> getDelegateInterfaces(Delegate d) {


+ 2
- 2
src/main/org/apache/tools/ant/dispatch/DispatchTask.java View File

@@ -23,8 +23,8 @@ import org.apache.tools.ant.Task;
* Tasks extending this class may contain multiple actions. * Tasks extending this class may contain multiple actions.
* The method that is invoked for execution depends upon the * The method that is invoked for execution depends upon the
* value of the action attribute of the task. * value of the action attribute of the task.
* <br/>
* Example:<br/>
* <br>
* Example:<br>
* &lt;mytask action=&quot;list&quot;/&gt; will invoke the method * &lt;mytask action=&quot;list&quot;/&gt; will invoke the method
* with the signature public void list() in mytask's class. * with the signature public void list() in mytask's class.
* If the action attribute is not defined in the task or is empty, * If the action attribute is not defined in the task or is empty,


+ 9
- 8
src/main/org/apache/tools/ant/filters/ConcatFilter.java View File

@@ -27,15 +27,16 @@ import org.apache.tools.ant.types.Parameter;
/** /**
* Concats a file before and/or after the file. * Concats a file before and/or after the file.
* *
* <p>Example:<pre>
* <copy todir="build">
* <fileset dir="src" includes="*.java"/>
* <filterchain>
* <concatfilter prepend="apache-license-java.txt"/>
* </filterchain>
* </copy>
* <p>Example:</p><pre>
* &lt;copy todir="build"&gt;
* &lt;fileset dir="src" includes="*.java"/&gt;
* &lt;filterchain&gt;
* &lt;concatfilter prepend="apache-license-java.txt"/&gt;
* &lt;/filterchain&gt;
* &lt;/copy&gt;
* </pre> * </pre>
* Copies all java sources from <i>src</i> to <i>build</i> and adds the
*
* <p>Copies all java sources from <i>src</i> to <i>build</i> and adds the
* content of <i>apache-license-java.txt</i> add the beginning of each * content of <i>apache-license-java.txt</i> add the beginning of each
* file.</p> * file.</p>
* *


+ 4
- 4
src/main/org/apache/tools/ant/filters/TokenFilter.java View File

@@ -365,7 +365,7 @@ public class TokenFilter extends BaseFilterReader


/** /**
* Filter a string 'line' replacing from with to * Filter a string 'line' replacing from with to
* (C&P from the Replace task)
* (Copy&amp;Paste from the Replace task)
* @param line the string to be filtered * @param line the string to be filtered
* @return the filtered line * @return the filtered line
*/ */
@@ -684,7 +684,7 @@ public class TokenFilter extends BaseFilterReader
* xml does not do "c" like interpretation of strings. * xml does not do "c" like interpretation of strings.
* i.e. \n\r\t etc. * i.e. \n\r\t etc.
* this method processes \n, \r, \t, \f, \\ * this method processes \n, \r, \t, \f, \\
* also subs \s -> " \n\r\t\f"
* also subs \s with " \n\r\t\f"
* a trailing '\' will be ignored * a trailing '\' will be ignored
* *
* @param input raw string with possible embedded '\'s * @param input raw string with possible embedded '\'s
@@ -696,12 +696,12 @@ public class TokenFilter extends BaseFilterReader


/** /**
* convert regex option flag characters to regex options * convert regex option flag characters to regex options
* <dl>
* <ul>
* <li>g - Regexp.REPLACE_ALL</li> * <li>g - Regexp.REPLACE_ALL</li>
* <li>i - Regexp.MATCH_CASE_INSENSITIVE</li> * <li>i - Regexp.MATCH_CASE_INSENSITIVE</li>
* <li>m - Regexp.MATCH_MULTILINE</li> * <li>m - Regexp.MATCH_MULTILINE</li>
* <li>s - Regexp.MATCH_SINGLELINE</li> * <li>s - Regexp.MATCH_SINGLELINE</li>
* </dl>
* </ul>
* @param flags the string containing the flags * @param flags the string containing the flags
* @return the Regexp option bits * @return the Regexp option bits
*/ */


+ 43
- 39
src/main/org/apache/tools/ant/listener/AnsiColorLogger.java View File

@@ -29,72 +29,76 @@ import org.apache.tools.ant.Project;
* Uses ANSI Color Code Sequences to colorize messages * Uses ANSI Color Code Sequences to colorize messages
* sent to the console. * sent to the console.
* *
* If used with the -logfile option, the output file
* <p>If used with the -logfile option, the output file
* will contain all the necessary escape codes to * will contain all the necessary escape codes to
* display the text in colorized mode when displayed * display the text in colorized mode when displayed
* in the console using applications like cat, more, * in the console using applications like cat, more,
* etc.
* etc.</p>
* *
* This is designed to work on terminals that support ANSI
* <p>This is designed to work on terminals that support ANSI
* color codes. It works on XTerm, ETerm, Mindterm, etc. * color codes. It works on XTerm, ETerm, Mindterm, etc.
* It also works on Win9x (with ANSI.SYS loaded.)
* It also works on Win9x (with ANSI.SYS loaded.)</p>
* *
* NOTE:
* <p>NOTE:
* It doesn't work on WinNT's COMMAND.COM even with * It doesn't work on WinNT's COMMAND.COM even with
* ANSI.SYS loaded.
* ANSI.SYS loaded.</p>
* *
* The default colors used for differentiating
* <p>The default colors used for differentiating
* the message levels can be changed by editing the * the message levels can be changed by editing the
* /org/apache/tools/ant/listener/defaults.properties * /org/apache/tools/ant/listener/defaults.properties
* file. * file.
* This file contains 5 key/value pairs:
* This file contains 5 key/value pairs:</p>
* <pre>
* AnsiColorLogger.ERROR_COLOR=2;31 * AnsiColorLogger.ERROR_COLOR=2;31
* AnsiColorLogger.WARNING_COLOR=2;35 * AnsiColorLogger.WARNING_COLOR=2;35
* AnsiColorLogger.INFO_COLOR=2;36 * AnsiColorLogger.INFO_COLOR=2;36
* AnsiColorLogger.VERBOSE_COLOR=2;32 * AnsiColorLogger.VERBOSE_COLOR=2;32
* AnsiColorLogger.DEBUG_COLOR=2;34 * AnsiColorLogger.DEBUG_COLOR=2;34
* </pre>
* *
* Another option is to pass a system variable named
* <p>Another option is to pass a system variable named
* ant.logger.defaults, with value set to the path of * ant.logger.defaults, with value set to the path of
* the file that contains user defined Ansi Color * the file that contains user defined Ansi Color
* Codes, to the <B>java</B> command using -D option.
* Codes, to the <B>java</B> command using -D option.</p>
* *
* To change these colors use the following chart: * To change these colors use the following chart:
* *
* <B>ANSI COLOR LOGGER CONFIGURATION</B>
* <h2>ANSI COLOR LOGGER CONFIGURATION</h2>
* *
* Format for AnsiColorLogger.*= * Format for AnsiColorLogger.*=
* Attribute;Foreground;Background * Attribute;Foreground;Background
* *
* Attribute is one of the following:
* 0 -> Reset All Attributes (return to normal mode)
* 1 -> Bright (Usually turns on BOLD)
* 2 -> Dim
* 3 -> Underline
* 5 -> link
* 7 -> Reverse
* 8 -> Hidden
*
* Foreground is one of the following:
* 30 -> Black
* 31 -> Red
* 32 -> Green
* 33 -> Yellow
* 34 -> Blue
* 35 -> Magenta
* 36 -> Cyan
* 37 -> White
*
* Background is one of the following:
* 40 -> Black
* 41 -> Red
* 42 -> Green
* 43 -> Yellow
* 44 -> Blue
* 45 -> Magenta
* 46 -> Cyan
* 47 -> White
* Attribute is one of the following: <pre>
* 0 -&gt; Reset All Attributes (return to normal mode)
* 1 -&gt; Bright (Usually turns on BOLD)
* 2 -&gt; Dim
* 3 -&gt; Underline
* 5 -&gt; link
* 7 -&gt; Reverse
* 8 -&gt; Hidden
* </pre>
*
* Foreground is one of the following:<pre>
* 30 -&gt; Black
* 31 -&gt; Red
* 32 -&gt; Green
* 33 -&gt; Yellow
* 34 -&gt; Blue
* 35 -&gt; Magenta
* 36 -&gt; Cyan
* 37 -&gt; White
* </pre>
* *
* Background is one of the following:<pre>
* 40 -&gt; Black
* 41 -&gt; Red
* 42 -&gt; Green
* 43 -&gt; Yellow
* 44 -&gt; Blue
* 45 -&gt; Magenta
* 46 -&gt; Cyan
* 47 -&gt; White
* </pre>
*/ */
public class AnsiColorLogger extends DefaultLogger { public class AnsiColorLogger extends DefaultLogger {
// private static final int ATTR_NORMAL = 0; // private static final int ATTR_NORMAL = 0;


+ 7
- 6
src/main/org/apache/tools/ant/taskdefs/Ant.java View File

@@ -24,21 +24,22 @@ import java.io.IOException;
import java.io.PrintStream; import java.io.PrintStream;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import java.util.Enumeration; import java.util.Enumeration;
import java.util.HashSet;
import java.util.Hashtable; import java.util.Hashtable;
import java.util.Iterator; import java.util.Iterator;
import java.util.Vector;
import java.util.Set; import java.util.Set;
import java.util.HashSet;
import java.util.Vector;

import org.apache.tools.ant.BuildException; import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.BuildListener; import org.apache.tools.ant.BuildListener;
import org.apache.tools.ant.DefaultLogger; import org.apache.tools.ant.DefaultLogger;
import org.apache.tools.ant.MagicNames;
import org.apache.tools.ant.Main;
import org.apache.tools.ant.Project; import org.apache.tools.ant.Project;
import org.apache.tools.ant.ProjectComponent; import org.apache.tools.ant.ProjectComponent;
import org.apache.tools.ant.ProjectHelper; import org.apache.tools.ant.ProjectHelper;
import org.apache.tools.ant.Target; import org.apache.tools.ant.Target;
import org.apache.tools.ant.Task; import org.apache.tools.ant.Task;
import org.apache.tools.ant.MagicNames;
import org.apache.tools.ant.Main;
import org.apache.tools.ant.types.PropertySet; import org.apache.tools.ant.types.PropertySet;
import org.apache.tools.ant.util.FileUtils; import org.apache.tools.ant.util.FileUtils;
import org.apache.tools.ant.util.VectorSet; import org.apache.tools.ant.util.VectorSet;
@@ -51,8 +52,8 @@ import org.apache.tools.ant.util.VectorSet;
* &lt;ant antfile=&quot;build.xml&quot; target=&quot;bar&quot; &gt; * &lt;ant antfile=&quot;build.xml&quot; target=&quot;bar&quot; &gt;
* &lt;property name=&quot;property1&quot; value=&quot;aaaaa&quot; /&gt; * &lt;property name=&quot;property1&quot; value=&quot;aaaaa&quot; /&gt;
* &lt;property name=&quot;foo&quot; value=&quot;baz&quot; /&gt; * &lt;property name=&quot;foo&quot; value=&quot;baz&quot; /&gt;
* &lt;/ant&gt;</span>
* &lt;/target&gt;</span>
* &lt;/ant&gt;
* &lt;/target&gt;
* *
* &lt;target name=&quot;bar&quot; depends=&quot;init&quot;&gt; * &lt;target name=&quot;bar&quot; depends=&quot;init&quot;&gt;
* &lt;echo message=&quot;prop is ${property1} ${foo}&quot; /&gt; * &lt;echo message=&quot;prop is ${property1} ${foo}&quot; /&gt;


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Apt.java View File

@@ -48,7 +48,7 @@ public class Apt
/** An warning message when ignoring compiler attribute. */ /** An warning message when ignoring compiler attribute. */
public static final String ERROR_IGNORING_COMPILER_OPTION public static final String ERROR_IGNORING_COMPILER_OPTION
= "Ignoring compiler attribute for the APT task, as it is fixed"; = "Ignoring compiler attribute for the APT task, as it is fixed";
/** A warning message if used with java < 1.5. */
/** A warning message if used with java &lt; 1.5. */
public static final String ERROR_WRONG_JAVA_VERSION public static final String ERROR_WRONG_JAVA_VERSION
= "Apt task requires Java 1.5+"; = "Apt task requires Java 1.5+";




+ 4
- 5
src/main/org/apache/tools/ant/taskdefs/Componentdef.java View File

@@ -20,10 +20,10 @@ package org.apache.tools.ant.taskdefs;


/** /**
* Adds a component definition to the current project. * Adds a component definition to the current project.
* used in the current project. Two attributes are needed, the name that identifies
* this component uniquely, and the full name of the class (
* including the packages) that
* <p>Used in the current project two attributes are needed, the name that identifies
* this component uniquely, and the full name of the class (including the packages) that
* implements this component.</p> * implements this component.</p>
*
* @since Ant 1.8 * @since Ant 1.8
* @ant.task category="internal" * @ant.task category="internal"
*/ */
@@ -31,10 +31,9 @@ public class Componentdef extends Definer {


/** /**
* Default constructor. * Default constructor.
* Creates a new ComponentDef instance.
* Creates a new Componentdef instance.
* Sets the restrict attribute to true. * Sets the restrict attribute to true.
*/ */

public Componentdef() { public Componentdef() {
setRestrict(true); setRestrict(true);
} }


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Concat.java View File

@@ -813,7 +813,7 @@ public class Concat extends Task implements ResourceCollection {


/** /**
* Implement ResourceCollection. * Implement ResourceCollection.
* @return Iterator<Resource>.
* @return Iterator&lt;Resource&gt;.
*/ */
public Iterator<Resource> iterator() { public Iterator<Resource> iterator() {
validate(); validate();


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Copy.java View File

@@ -50,7 +50,7 @@ import org.apache.tools.ant.util.SourceFileScanner;
import org.apache.tools.ant.util.FlatFileNameMapper; import org.apache.tools.ant.util.FlatFileNameMapper;


/** /**
* Copies a file or directory to a new file
* <p>Copies a file or directory to a new file
* or directory. Files are only copied if the source file is newer * or directory. Files are only copied if the source file is newer
* than the destination file, or when the destination file does not * than the destination file, or when the destination file does not
* exist. It is possible to explicitly overwrite existing files.</p> * exist. It is possible to explicitly overwrite existing files.</p>


+ 2
- 2
src/main/org/apache/tools/ant/taskdefs/Definer.java View File

@@ -155,11 +155,11 @@ public abstract class Definer extends DefBase {


/** /**
* What to do if there is an error in loading the class. * What to do if there is an error in loading the class.
* <dl>
* <ul>
* <li>error - throw build exception</li> * <li>error - throw build exception</li>
* <li>report - output at warning level</li> * <li>report - output at warning level</li>
* <li>ignore - output at debug level</li> * <li>ignore - output at debug level</li>
* </dl>
* </ul>
* *
* @param onError an <code>OnError</code> value * @param onError an <code>OnError</code> value
*/ */


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Exit.java View File

@@ -37,7 +37,7 @@ import org.apache.tools.ant.taskdefs.condition.ConditionBase;
* *
* If both attributes are set, then the test fails only if both tests * If both attributes are set, then the test fails only if both tests
* are true. i.e. * are true. i.e.
* <pre>fail := defined(ifProperty) && !defined(unlessProperty)</pre>
* <pre>fail := defined(ifProperty) &amp;&amp; !defined(unlessProperty)</pre>
* *
* A single nested<code>&lt;condition&gt;</code> element can be specified * A single nested<code>&lt;condition&gt;</code> element can be specified
* instead of using <code>if</code>/<code>unless</code> (a combined * instead of using <code>if</code>/<code>unless</code> (a combined


+ 4
- 8
src/main/org/apache/tools/ant/taskdefs/JDBCTask.java View File

@@ -41,8 +41,9 @@ import org.apache.tools.ant.types.Reference;
* <p> * <p>
* The following example class prints the contents of the first column of each row in TableName. * The following example class prints the contents of the first column of each row in TableName.
*</p> *</p>
*<code><pre>
*<pre>
package examples; package examples;

import java.sql.Connection; import java.sql.Connection;
import java.sql.ResultSet; import java.sql.ResultSet;
import java.sql.SQLException; import java.sql.SQLException;
@@ -84,16 +85,11 @@ public class SQLExampleTask extends JDBCTask {
} }


} }


</pre></code>



</pre>
*
* @since Ant 1.5 * @since Ant 1.5
* *
*/ */

public abstract class JDBCTask extends Task { public abstract class JDBCTask extends Task {
private static final int HASH_TABLE_SIZE = 3; private static final int HASH_TABLE_SIZE = 3;




+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Javac.java View File

@@ -172,7 +172,7 @@ public class Javac extends MatchingTask {
* Keyword list to be appended to the -g command-line switch. * Keyword list to be appended to the -g command-line switch.
* *
* This will be ignored by all implementations except modern * This will be ignored by all implementations except modern
* and classic(ver >= 1.2). Legal values are none or a
* and classic(ver &gt;= 1.2). Legal values are none or a
* comma-separated list of the following keywords: lines, vars, * comma-separated list of the following keywords: lines, vars,
* and source. If debuglevel is not specified, by default, :none * and source. If debuglevel is not specified, by default, :none
* will be appended to -g. If debug is not turned on, this attribute * will be appended to -g. If debug is not turned on, this attribute


+ 3
- 3
src/main/org/apache/tools/ant/taskdefs/Javadoc.java View File

@@ -29,7 +29,6 @@ import java.io.FilenameFilter;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.OutputStreamWriter; import java.io.OutputStreamWriter;
import java.net.MalformedURLException; import java.net.MalformedURLException;
import java.net.URL; import java.net.URL;
@@ -40,6 +39,7 @@ import java.util.Iterator;
import java.util.Locale; import java.util.Locale;
import java.util.StringTokenizer; import java.util.StringTokenizer;
import java.util.Vector; import java.util.Vector;

import org.apache.tools.ant.BuildException; import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.DirectoryScanner; import org.apache.tools.ant.DirectoryScanner;
import org.apache.tools.ant.MagicNames; import org.apache.tools.ant.MagicNames;
@@ -57,8 +57,8 @@ import org.apache.tools.ant.types.Resource;
import org.apache.tools.ant.types.ResourceCollection; import org.apache.tools.ant.types.ResourceCollection;
import org.apache.tools.ant.types.resources.FileProvider; import org.apache.tools.ant.types.resources.FileProvider;
import org.apache.tools.ant.util.FileUtils; import org.apache.tools.ant.util.FileUtils;
import org.apache.tools.ant.util.StringUtils;
import org.apache.tools.ant.util.JavaEnvUtils; import org.apache.tools.ant.util.JavaEnvUtils;
import org.apache.tools.ant.util.StringUtils;


/** /**
* Generates Javadoc documentation for a collection * Generates Javadoc documentation for a collection
@@ -918,7 +918,7 @@ public class Javadoc extends Task {
} }


/** /**
* Generate the &quot;use&quot page for each package.
* Generate the &quot;use&quot; page for each package.
* *
* @param b true if the use page should be generated. * @param b true if the use page should be generated.
*/ */


+ 5
- 5
src/main/org/apache/tools/ant/taskdefs/MakeUrl.java View File

@@ -32,11 +32,11 @@ import java.util.LinkedList;
import java.util.ListIterator; import java.util.ListIterator;


/** /**
* This task takes file and turns them into a URL, which it then assigns
* to a property. Use when for setting up RMI codebases.
* <p/>
* nested filesets are supported; if present, these are turned into the
* url with the given separator between them (default = " ").
* <p>This task takes file and turns them into a URL, which it then assigns
* to a property. Use when for setting up RMI codebases.</p>
*
* <p>nested filesets are supported; if present, these are turned into the
* url with the given separator between them (default = " ").</p>
* *
* @ant.task category="core" name="makeurl" * @ant.task category="core" name="makeurl"
*/ */


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Patch.java View File

@@ -107,7 +107,7 @@ public class Patch extends Task {
* *
* <p>patch's <i>-p</i> option. * <p>patch's <i>-p</i> option.
* @param num number of lines to strip * @param num number of lines to strip
* @exception BuildException if num is < 0, or other errors
* @exception BuildException if num is &lt; 0, or other errors
*/ */
public void setStrip(int num) throws BuildException { public void setStrip(int num) throws BuildException {
if (num < 0) { if (num < 0) {


+ 3
- 5
src/main/org/apache/tools/ant/taskdefs/Property.java View File

@@ -22,27 +22,25 @@ import java.io.FileInputStream;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
import java.net.URL; import java.net.URL;
import java.util.Enumeration;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.Map; import java.util.Map;
import java.util.Properties; import java.util.Properties;
import java.util.Vector;


import org.apache.tools.ant.AntClassLoader; import org.apache.tools.ant.AntClassLoader;
import org.apache.tools.ant.BuildException; import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Project; import org.apache.tools.ant.Project;
import org.apache.tools.ant.PropertyHelper; import org.apache.tools.ant.PropertyHelper;
import org.apache.tools.ant.Task; import org.apache.tools.ant.Task;
import org.apache.tools.ant.property.ResolvePropertyMap;
import org.apache.tools.ant.types.Path; import org.apache.tools.ant.types.Path;
import org.apache.tools.ant.types.Reference; import org.apache.tools.ant.types.Reference;
import org.apache.tools.ant.util.FileUtils; import org.apache.tools.ant.util.FileUtils;
import org.apache.tools.ant.property.ResolvePropertyMap;


/** /**
* Sets a property by name, or set of properties (from file or
* <p>Sets a property by name, or set of properties (from file or
* resource) in the project. </p> * resource) in the project. </p>
* Properties are immutable: whoever sets a property first freezes it for the
* <p>Properties are immutable: whoever sets a property first freezes it for the
* rest of the build; they are most definitely not variable. * rest of the build; they are most definitely not variable.
* <p>There are seven ways to set properties:</p> * <p>There are seven ways to set properties:</p>
* <ul> * <ul>


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Redirector.java View File

@@ -370,7 +370,7 @@ public class Redirector {
/** /**
* This <code>Redirector</code>'s subordinate * This <code>Redirector</code>'s subordinate
* <code>PropertyOutputStream</code>s will not set their respective * <code>PropertyOutputStream</code>s will not set their respective
* properties <code>while (appendProperties && append)</code>.
* properties <code>while (appendProperties &amp;&amp; append)</code>.
* *
* @param appendProperties * @param appendProperties
* whether to append properties. * whether to append properties.


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Replace.java View File

@@ -214,7 +214,7 @@ public class Replace extends MatchingTask {
} }


/** /**
* The replacement string; required if <code>property<code>
* The replacement string; required if <code>property</code>
* is not set. * is not set.
* @param value <code>String</code> value to replace. * @param value <code>String</code> value to replace.
*/ */


+ 2
- 2
src/main/org/apache/tools/ant/taskdefs/Retry.java View File

@@ -67,12 +67,12 @@ public class Retry extends Task implements TaskContainer {


/** /**
* set the delay between retries (in milliseconds) * set the delay between retries (in milliseconds)
* @param n the time between retries.
* @param retryDelay the time between retries.
* @since Ant 1.8.3 * @since Ant 1.8.3
*/ */
public void setRetryDelay(int retryDelay) { public void setRetryDelay(int retryDelay) {
if (retryDelay < 0) { if (retryDelay < 0) {
throw new BuildException("delay must be a non-negative number");
throw new BuildException("retryDelay must be a non-negative number");
} }
this.retryDelay = retryDelay; this.retryDelay = retryDelay;
} }


+ 7
- 2
src/main/org/apache/tools/ant/taskdefs/Rmic.java View File

@@ -37,13 +37,15 @@ import org.apache.tools.ant.util.StringUtils;
import org.apache.tools.ant.util.facade.FacadeTaskHelper; import org.apache.tools.ant.util.facade.FacadeTaskHelper;


/** /**
* Runs the rmic compiler against classes.</p>
* <p>Runs the rmic compiler against classes.</p>
*
* <p>Rmic can be run on a single class (as specified with the classname * <p>Rmic can be run on a single class (as specified with the classname
* attribute) or a number of classes at once (all classes below base that * attribute) or a number of classes at once (all classes below base that
* are neither _Stub nor _Skel classes). If you want to rmic a single * are neither _Stub nor _Skel classes). If you want to rmic a single
* class and this class is a class nested into another class, you have to * class and this class is a class nested into another class, you have to
* specify the classname in the form <code>Outer$$Inner</code> instead of * specify the classname in the form <code>Outer$$Inner</code> instead of
* <code>Outer.Inner</code>.</p> * <code>Outer.Inner</code>.</p>
*
* <p>It is possible to refine the set of files that are being rmiced. This can * <p>It is possible to refine the set of files that are being rmiced. This can
* be done with the <i>includes</i>, <i>includesfile</i>, <i>excludes</i>, * be done with the <i>includes</i>, <i>includesfile</i>, <i>excludes</i>,
* <i>excludesfile</i> and <i>defaultexcludes</i> * <i>excludesfile</i> and <i>defaultexcludes</i>
@@ -53,16 +55,19 @@ import org.apache.tools.ant.util.facade.FacadeTaskHelper;
* the files you want to have excluded. This is also done with patterns. And * the files you want to have excluded. This is also done with patterns. And
* finally with the <i>defaultexcludes</i> attribute, you can specify whether * finally with the <i>defaultexcludes</i> attribute, you can specify whether
* you want to use default exclusions or not. See the section on * you want to use default exclusions or not. See the section on
* directory based tasks</a>, on how the
* directory based tasks, on how the
* inclusion/exclusion of files works, and how to write patterns.</p> * inclusion/exclusion of files works, and how to write patterns.</p>
*
* <p>This task forms an implicit FileSet and * <p>This task forms an implicit FileSet and
* supports all attributes of <code>&lt;fileset&gt;</code> * supports all attributes of <code>&lt;fileset&gt;</code>
* (<code>dir</code> becomes <code>base</code>) as well as the nested * (<code>dir</code> becomes <code>base</code>) as well as the nested
* <code>&lt;include&gt;</code>, <code>&lt;exclude&gt;</code> and * <code>&lt;include&gt;</code>, <code>&lt;exclude&gt;</code> and
* <code>&lt;patternset&gt;</code> elements.</p> * <code>&lt;patternset&gt;</code> elements.</p>
*
* <p>It is possible to use different compilers. This can be selected * <p>It is possible to use different compilers. This can be selected
* with the &quot;build.rmic&quot; property or the <code>compiler</code> * with the &quot;build.rmic&quot; property or the <code>compiler</code>
* attribute. <a name="compilervalues">There are three choices</a>:</p> * attribute. <a name="compilervalues">There are three choices</a>:</p>
*
* <ul> * <ul>
* <li>sun (the standard compiler of the JDK)</li> * <li>sun (the standard compiler of the JDK)</li>
* <li>kaffe (the standard compiler of * <li>kaffe (the standard compiler of


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/SQLExec.java View File

@@ -542,7 +542,7 @@ public class SQLExec extends JDBCTask {
* will be quoted, not even if they contain the column * will be quoted, not even if they contain the column
* separator.</p> * separator.</p>
* *
* <p><b>Note:<b> BLOB values will never be quoted.</p>
* <p><b>Note:</b> BLOB values will never be quoted.</p>
* *
* <p>Defaults to "not set"</p> * <p>Defaults to "not set"</p>
* *


+ 5
- 5
src/main/org/apache/tools/ant/taskdefs/SignJar.java View File

@@ -511,13 +511,13 @@ public class SignJar extends AbstractJarSignerTask {
} }


/** /**
* Compare a jar file with its corresponding signed jar. The logic for this
* <p>Compare a jar file with its corresponding signed jar. The logic for this
* is complex, and best explained in the source itself. Essentially if * is complex, and best explained in the source itself. Essentially if
* either file doesnt exist, or the destfile has an out of date timestamp, * either file doesnt exist, or the destfile has an out of date timestamp,
* then the return value is false.
* <p/>
* If we are signing ourself, the check {@link #isSigned(File)} is used to
* trigger the process.
* then the return value is false.</p>
*
* <p>If we are signing ourself, the check {@link #isSigned(File)} is used to
* trigger the process.</p>
* *
* @param jarFile the unsigned jar file * @param jarFile the unsigned jar file
* @param signedjarFile the result signed jar file * @param signedjarFile the result signed jar file


+ 6
- 6
src/main/org/apache/tools/ant/taskdefs/Sleep.java View File

@@ -24,13 +24,14 @@ import org.apache.tools.ant.Task;
/** /**
* Sleep, or pause, for a period of time. * Sleep, or pause, for a period of time.
* *
* A task for sleeping a short period of time, useful when a
* build or deployment process requires an interval between tasks.
*<p>
* A negative value can be supplied to any of attributes provided the total sleep time
* <p>A task for sleeping a short period of time, useful when a
* build or deployment process requires an interval between tasks.</p>
*
* <p>A negative value can be supplied to any of attributes provided the total sleep time
* is positive, pending fundamental changes in physics and JVM * is positive, pending fundamental changes in physics and JVM
* execution times</p> * execution times</p>
* Note that sleep times are always hints to be interpreted by the OS how it feels
*
* <p>Note that sleep times are always hints to be interpreted by the OS how it feels
* small times may either be ignored or rounded up to a minimum timeslice. Note * small times may either be ignored or rounded up to a minimum timeslice. Note
* also that the system clocks often have a fairly low granularity too, which complicates * also that the system clocks often have a fairly low granularity too, which complicates
* measuring how long a sleep actually took.</p> * measuring how long a sleep actually took.</p>
@@ -38,7 +39,6 @@ import org.apache.tools.ant.Task;
* @since Ant 1.4 * @since Ant 1.4
* @ant.task category="utility" * @ant.task category="utility"
*/ */

public class Sleep extends Task { public class Sleep extends Task {
/** /**
* failure flag * failure flag


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/Tar.java View File

@@ -611,7 +611,7 @@ public class Tar extends MatchingTask {
} }


/** /**
* Checks whether the archive is out-of-date with respect to the
* <p>Checks whether the archive is out-of-date with respect to the
* given files, ensures that the archive won't contain itself.</p> * given files, ensures that the archive won't contain itself.</p>
* *
* @param basedir base directory for file names * @param basedir base directory for file names


+ 3
- 4
src/main/org/apache/tools/ant/taskdefs/Taskdef.java View File

@@ -22,14 +22,13 @@ import org.apache.tools.ant.Task;
import org.apache.tools.ant.TaskAdapter; import org.apache.tools.ant.TaskAdapter;


/** /**
* Adds a task definition to the current project, such that this new task can be
* <p>Adds a task definition to the current project, such that this new task can be
* used in the current project. Two attributes are needed, the name that identifies * used in the current project. Two attributes are needed, the name that identifies
* this task uniquely, and the full name of the class (including the packages) that * this task uniquely, and the full name of the class (including the packages) that
* implements this task.</p> * implements this task.</p>
* <p>You can also define a group of tasks at once using the file or * <p>You can also define a group of tasks at once using the file or
* resource attributes. These attributes point to files in the format of
* Java property files. Each line defines a single task in the
* format:</p>
* resource attributes. These attributes point to files in the format of
* Java property files. Each line defines a single task in the format:</p>
* <pre> * <pre>
* taskname=fully.qualified.java.classname * taskname=fully.qualified.java.classname
* </pre> * </pre>


+ 5
- 2
src/main/org/apache/tools/ant/taskdefs/War.java View File

@@ -28,13 +28,15 @@ import org.apache.tools.zip.ZipOutputStream;




/** /**
* An extension of &lt;jar&gt; to create a WAR archive.
* <p>An extension of &lt;jar&gt; to create a WAR archive.
* Contains special treatment for files that should end up in the * Contains special treatment for files that should end up in the
* <code>WEB-INF/lib</code>, <code>WEB-INF/classes</code> or * <code>WEB-INF/lib</code>, <code>WEB-INF/classes</code> or
* <code>WEB-INF</code> directories of the Web Application Archive.</p> * <code>WEB-INF</code> directories of the Web Application Archive.</p>
*
* <p>(The War task is a shortcut for specifying the particular layout of a WAR file. * <p>(The War task is a shortcut for specifying the particular layout of a WAR file.
* The same thing can be accomplished by using the <i>prefix</i> and <i>fullpath</i> * The same thing can be accomplished by using the <i>prefix</i> and <i>fullpath</i>
* attributes of zipfilesets in a Zip or Jar task.)</p> * attributes of zipfilesets in a Zip or Jar task.)</p>
*
* <p>The extended zipfileset element from the zip task * <p>The extended zipfileset element from the zip task
* (with attributes <i>prefix</i>, <i>fullpath</i>, and <i>src</i>) * (with attributes <i>prefix</i>, <i>fullpath</i>, and <i>src</i>)
* is available in the War task.</p> * is available in the War task.</p>
@@ -69,13 +71,14 @@ public class War extends Jar {
} }


/** /**
* <i>Deprecated<i> name of the file to create
* <i>Deprecated</i> name of the file to create
* -use <tt>destfile</tt> instead. * -use <tt>destfile</tt> instead.
* @param warFile the destination file * @param warFile the destination file
* @deprecated since 1.5.x. * @deprecated since 1.5.x.
* Use setDestFile(File) instead * Use setDestFile(File) instead
* @ant.attribute ignore="true" * @ant.attribute ignore="true"
*/ */
@Deprecated
public void setWarfile(File warFile) { public void setWarfile(File warFile) {
setDestFile(warFile); setDestFile(warFile);
} }


+ 11
- 13
src/main/org/apache/tools/ant/taskdefs/compilers/AptCompilerAdapter.java View File

@@ -31,25 +31,25 @@ import java.util.Vector;




/** /**
* The implementation of the apt compiler for JDK 1.5
* <p/>
* As usual, the low level entry points for Java tools are neither documented or
* <p>The implementation of the apt compiler for JDK 1.5.</p>
*
* <p>As usual, the low level entry points for Java tools are neither documented or
* stable; this entry point may change from that of 1.5.0_01-b08 without any * stable; this entry point may change from that of 1.5.0_01-b08 without any
* warning at all. The IDE decompile of the tool entry points is as follows:
* warning at all. The IDE decompile of the tool entry points is as follows:</p>
* <pre> * <pre>
* public class Main { * public class Main {
* public Main() ; * public Main() ;
* <p/>
* public static transient void main(String... strings) ;
* <p/>
*
* public static transient void main(String... strings);
*
* public static transient int process(String... strings); * public static transient int process(String... strings);
* <p/>
*
* public static transient int process(PrintWriter printWriter, * public static transient int process(PrintWriter printWriter,
* String... strings) ;
* String... strings);
* public static transient int process( * public static transient int process(
* AnnotationProcessorFactory annotationProcessorFactory, * AnnotationProcessorFactory annotationProcessorFactory,
* String... strings) ;
* <p/>
* String... strings);
*
* public static transient int process( * public static transient int process(
* AnnotationProcessorFactory annotationProcessorFactory, * AnnotationProcessorFactory annotationProcessorFactory,
* PrintWriter printWriter, * PrintWriter printWriter,
@@ -65,8 +65,6 @@ import java.util.Vector;
* exposed to end-users, because it was too brittle during beta testing; classpath * exposed to end-users, because it was too brittle during beta testing; classpath
* problems being the core issue. * problems being the core issue.
* *
*
*
* @since Ant 1.7 * @since Ant 1.7
*/ */
public class AptCompilerAdapter extends DefaultCompilerAdapter { public class AptCompilerAdapter extends DefaultCompilerAdapter {


+ 14
- 14
src/main/org/apache/tools/ant/taskdefs/condition/IsReachable.java View File

@@ -30,24 +30,24 @@ import java.net.URL;
import java.net.UnknownHostException; import java.net.UnknownHostException;


/** /**
* Test for a host being reachable using ICMP "ping" packets & echo operations.
* <p>Test for a host being reachable using ICMP "ping" packets &amp; echo operations.
* Ping packets are very reliable for assessing reachability in a LAN or WAN, * Ping packets are very reliable for assessing reachability in a LAN or WAN,
* but they do not get through any well-configured firewall. Echo (port 7) may.
* <p/>
* This condition turns unknown host exceptions into false conditions. This is
* but they do not get through any well-configured firewall. Echo (port 7) may.</p>
*
* <p>This condition turns unknown host exceptions into false conditions. This is
* because on a laptop, DNS is one of the first services lost when the network * because on a laptop, DNS is one of the first services lost when the network
* goes; you are implicitly offline.
* <p/>
* If a URL is supplied instead of a host, the hostname is extracted and used in
* the test--all other parts of the URL are discarded.
* <p/>
* The test may not work through firewalls; that is, something may be reachable
* goes; you are implicitly offline.</p>
*
* <p>If a URL is supplied instead of a host, the hostname is extracted and used in
* the test--all other parts of the URL are discarded.</p>
*
* <p>The test may not work through firewalls; that is, something may be reachable
* using a protocol such as HTTP, while the lower level ICMP packets get dropped * using a protocol such as HTTP, while the lower level ICMP packets get dropped
* on the floor. Similarly, a host may be detected as reachable with ICMP, but not * on the floor. Similarly, a host may be detected as reachable with ICMP, but not
* reachable on other ports (i.e. port 80), because of firewalls.
* <p/>
* Requires Java 5+ to work properly. On Java 1.4, if a hostname
* can be resolved, the destination is assumed to be reachable.
* reachable on other ports (i.e. port 80), because of firewalls.</p>
*
* <p>Requires Java 5+ to work properly. On Java 1.4, if a hostname
* can be resolved, the destination is assumed to be reachable.</p>
* *
* @since Ant 1.7 * @since Ant 1.7
*/ */


+ 2
- 2
src/main/org/apache/tools/ant/taskdefs/condition/Os.java View File

@@ -126,8 +126,8 @@ public class Os implements Condition {
/** /**
* Sets the desired OS family type * Sets the desired OS family type
* *
* @param f The OS family type desired<br />
* Possible values:<br />
* @param f The OS family type desired<br>
* Possible values:<br>
* <ul> * <ul>
* <li>dos</li> * <li>dos</li>
* <li>mac</li> * <li>mac</li>


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/cvslib/ChangeLogTask.java View File

@@ -133,7 +133,7 @@ public class ChangeLogTask extends AbstractCvsTask {




/** /**
* Set a lookup list of user names & addresses
* Set a lookup list of user names &amp; addresses
* *
* @param usersFile The file containing the users info. * @param usersFile The file containing the users info.
*/ */


+ 7
- 7
src/main/org/apache/tools/ant/taskdefs/email/EmailAddress.java View File

@@ -35,12 +35,12 @@ public class EmailAddress {
/** /**
* Creates a new email address based on the given string * Creates a new email address based on the given string
* *
* @param email the email address (with or without <>)
* @param email the email address (with or without &lt;&gt;)
* Acceptable forms include: * Acceptable forms include:
* address * address
* <address>
* name <address>
* <address> name
* &lt;address&gt;
* name &lt;address&gt;
* &lt;address&gt; name
* (name) address * (name) address
* address (name) * address (name)
*/ */
@@ -142,7 +142,7 @@ public class EmailAddress {




/** /**
* Sets the personal / display name of the address
* Sets the personal / display name of the address.
* *
* @param name the display name * @param name the display name
*/ */
@@ -152,9 +152,9 @@ public class EmailAddress {




/** /**
* Sets the email address
* Sets the email address.
* *
* @param address the actual email address (without <>)
* @param address the actual email address (without &lt;&gt;)
*/ */
public void setAddress(String address) { public void setAddress(String address) {
this.address = address; this.address = address;


+ 69
- 53
src/main/org/apache/tools/ant/taskdefs/optional/PropertyFile.java View File

@@ -43,69 +43,85 @@ import org.apache.tools.ant.types.EnumeratedAttribute;
import org.apache.tools.ant.util.FileUtils; import org.apache.tools.ant.util.FileUtils;


/** /**
*Modifies settings in a property file.
* Modifies settings in a property file.
* *
* <p>
*The following is an example of its usage:
* <ul>&lt;target name="setState"&gt;<br>
* <ul>&lt;property<br>
* <ul>name="header"<br>
* value="##Generated file - do not modify!"/&gt;<br>
* &lt;propertyfile file="apropfile.properties" comment="${header}"&gt;<br>
* &lt;entry key="product.version.major" type="int" value="5"/&gt;<br>
* &lt;entry key="product.version.minor" type="int" value="0"/&gt;<br>
* &lt;entry key="product.build.major" type="int" value="0" /&gt;<br>
* &lt;entry key="product.build.minor" type="int" operation="+" /&gt;<br>
* &lt;entry key="product.build.date" type="date" value="now" /&gt;<br>
* &lt;entry key="intSet" type="int" operation="=" value="681"/&gt;<br>
* &lt;entry key="intDec" type="int" operation="-"/&gt;<br>
* &lt;entry key="StringEquals" type="string" value="testValue"/&gt;<br>
* &lt;/propertyfile&gt;<br></ul>
* &lt;/target&gt;</ul><p>
* <p>The following is an example of its usage:</p>
* <pre>
* &lt;target name="setState"&gt;
* &lt;property
* name="header"
* value="##Generated file - do not modify!"/&gt;
* &lt;propertyfile file="apropfile.properties" comment="${header}"&gt;
* &lt;entry key="product.version.major" type="int" value="5"/&gt;
* &lt;entry key="product.version.minor" type="int" value="0"/&gt;
* &lt;entry key="product.build.major" type="int" value="0" /&gt;
* &lt;entry key="product.build.minor" type="int" operation="+" /&gt;
* &lt;entry key="product.build.date" type="date" value="now" /&gt;
* &lt;entry key="intSet" type="int" operation="=" value="681"/&gt;
* &lt;entry key="intDec" type="int" operation="-"/&gt;
* &lt;entry key="StringEquals" type="string" value="testValue"/&gt;
* &lt;/propertyfile&gt;
* &lt;/target&gt;
* </pre>
* *
*The &lt;propertyfile&gt; task must have:<br>
* <ul><li>file</li></ul>
*Other parameters are:<br>
* <ul><li>comment, key, operation, type and value (the final four being
* eliminated shortly)</li></ul>
* The &lt;propertyfile&gt; task must have:
* <ul>
* <li>file</li>
* </ul>
* Other parameters are:
* <ul>
* <li>comment</li>
* <li>key</li>
* <li>operation</li>
* <li>type</li>
* <li>value (the final four being eliminated shortly)</li>
* </ul>
* *
*The &lt;entry&gt; task must have:<br>
* <ul><li>key</li></ul>
*Other parameters are:<br>
* <ul><li>operation</li>
* <li>type</li>
* <li>value</li>
* <li>default</li>
* <li>unit</li>
* </ul>
* The &lt;entry&gt; task must have:
* <ul>
* <li>key</li>
* </ul>
* Other parameters are:
* <ul>
* <li>operation</li>
* <li>type</li>
* <li>value</li>
* <li>default</li>
* <li>unit</li>
* </ul>
* *
*If type is unspecified, it defaults to string
* If type is unspecified, it defaults to string.
* *
*Parameter values:<br>
* <ul><li>operation:</li>
* <ul><li>"=" (set -- default)</li>
* <li>"-" (dec)</li>
* <li>"+" (inc)</li>
*
* <li>type:</li>
* <ul><li>"int"</li>
* <li>"date"</li>
* <li>"string"</li></ul></ul>
*
* <li>value:</li>
* <ul><li>holds the default value, if the property
* Parameter values:
* <ul>
* <li>operation:</li>
* <ul>
* <li>"=" (set -- default)</li>
* <li>"-" (dec)</li>
* <li>"+" (inc)</li>
* </ul>
* <li>type:</li>
* <ul>
* <li>"int"</li>
* <li>"date"</li>
* <li>"string"</li>
* </ul>
* <li>value:</li>
* <ul>
* <li>holds the default value, if the property
* was not found in property file</li> * was not found in property file</li>
* <li>"now" In case of type "date", the
* <li>"now" In case of type "date", the
* value "now" will be replaced by the current * value "now" will be replaced by the current
* date/time and used even if a valid date was * date/time and used even if a valid date was
* found in the property file.</li></ul>
*
* found in the property file.</li>
* </ul>
* </ul>
* *
*String property types can only use the "=" operation.
*Int property types can only use the "=", "-" or "+" operations.<p>
* <p>String property types can only use the "=" operation.
* Int property types can only use the "=", "-" or "+" operations.<p>
* *
*The message property is used for the property file header, with "\\" being
*a newline delimiter character.
* The message property is used for the property file header, with "\\" being
* a newline delimiter character.
* *
*/ */
public class PropertyFile extends Task { public class PropertyFile extends Task {


+ 5
- 3
src/main/org/apache/tools/ant/taskdefs/optional/ReplaceRegExp.java View File

@@ -212,11 +212,13 @@ public class ReplaceRegExp extends Task {
* on one line at a time. This is useful if you * on one line at a time. This is useful if you
* want to only replace the first occurrence of a regular expression on * want to only replace the first occurrence of a regular expression on
* each line, which is not easy to do when processing the file as a whole. * each line, which is not easy to do when processing the file as a whole.
* Defaults to <i>false</i>.</td>
* Defaults to <i>false</i>.
*
* @param byline the byline attribute as a string * @param byline the byline attribute as a string
* @deprecated since 1.6.x. * @deprecated since 1.6.x.
* Use setByLine(boolean). * Use setByLine(boolean).
*/ */
@Deprecated
public void setByLine(String byline) { public void setByLine(String byline) {
Boolean res = Boolean.valueOf(byline); Boolean res = Boolean.valueOf(byline);


@@ -231,14 +233,14 @@ public class ReplaceRegExp extends Task {
* on one line at a time. This is useful if you * on one line at a time. This is useful if you
* want to only replace the first occurrence of a regular expression on * want to only replace the first occurrence of a regular expression on
* each line, which is not easy to do when processing the file as a whole. * each line, which is not easy to do when processing the file as a whole.
* Defaults to <i>false</i>.</td>
* Defaults to <i>false</i>.
*
* @param byline the byline attribute * @param byline the byline attribute
*/ */
public void setByLine(boolean byline) { public void setByLine(boolean byline) {
this.byline = byline; this.byline = byline;
} }



/** /**
* Specifies the encoding Ant expects the files to be in - * Specifies the encoding Ant expects the files to be in -
* defaults to the platforms default encoding. * defaults to the platforms default encoding.


+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/optional/XMLValidateTask.java View File

@@ -120,7 +120,7 @@ public class XMLValidateTask extends Task {
/** /**
* Specify how parser error are to be handled. * Specify how parser error are to be handled.
* <p> * <p>
* If set to <code>true</true> (default), log a warn message for each SAX warn event.
* If set to <code>true</code> (default), log a warn message for each SAX warn event.
* @param bool if set to <code>false</code> do not send warnings * @param bool if set to <code>false</code> do not send warnings
*/ */
public void setWarn(boolean bool) { public void setWarn(boolean bool) {


+ 8
- 8
src/main/org/apache/tools/ant/taskdefs/optional/clearcase/CCCheckin.java View File

@@ -38,42 +38,42 @@ import org.apache.tools.ant.types.Commandline;
* <td>viewpath</td> * <td>viewpath</td>
* <td>Path to the ClearCase view file or directory that the command will operate on</td> * <td>Path to the ClearCase view file or directory that the command will operate on</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>comment</td> * <td>comment</td>
* <td>Specify a comment. Only one of comment or cfile may be used.</td> * <td>Specify a comment. Only one of comment or cfile may be used.</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>commentfile</td> * <td>commentfile</td>
* <td>Specify a file containing a comment. Only one of comment or cfile may be used.</td> * <td>Specify a file containing a comment. Only one of comment or cfile may be used.</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>nowarn</td> * <td>nowarn</td>
* <td>Suppress warning messages</td> * <td>Suppress warning messages</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>preservetime</td> * <td>preservetime</td>
* <td>Preserve the modification time</td> * <td>Preserve the modification time</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>keepcopy</td> * <td>keepcopy</td>
* <td>Keeps a copy of the file with a .keep extension</td> * <td>Keeps a copy of the file with a .keep extension</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>identical</td> * <td>identical</td>
* <td>Allows the file to be checked in even if it is identical to the original</td> * <td>Allows the file to be checked in even if it is identical to the original</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* <tr> * <tr>
* <td>failonerr</td> * <td>failonerr</td>
* <td>Throw an exception if the command fails. Default is true</td> * <td>Throw an exception if the command fails. Default is true</td>
* <td>No</td> * <td>No</td>
* <tr>
* </tr>
* </table> * </table>
* *
*/ */


Loading…
Cancel
Save