diff --git a/check.xml b/check.xml index 779d3d03a..91ccf4168 100755 --- a/check.xml +++ b/check.xml @@ -1,13 +1,15 @@ - + + + allowProtected="true" + javadocScope="${javadoc.scope}"> diff --git a/src/main/org/apache/tools/ant/filters/StringInputStream.java b/src/main/org/apache/tools/ant/filters/StringInputStream.java index 87989e363..bb1bfbf65 100644 --- a/src/main/org/apache/tools/ant/filters/StringInputStream.java +++ b/src/main/org/apache/tools/ant/filters/StringInputStream.java @@ -100,7 +100,7 @@ public class StringInputStream } /** - * Resetthe StringReader + * Reset the StringReader. */ public synchronized void reset() throws IOException { in.reset(); diff --git a/src/main/org/apache/tools/ant/taskdefs/AbstractCvsTask.java b/src/main/org/apache/tools/ant/taskdefs/AbstractCvsTask.java index 943967766..a31f1d1fb 100644 --- a/src/main/org/apache/tools/ant/taskdefs/AbstractCvsTask.java +++ b/src/main/org/apache/tools/ant/taskdefs/AbstractCvsTask.java @@ -182,11 +182,11 @@ public abstract class AbstractCvsTask extends Task { super(); } - public void setExecuteStreamHandler(ExecuteStreamHandler handler){ + public void setExecuteStreamHandler(ExecuteStreamHandler handler) { this.executeStreamHandler = handler; } - protected ExecuteStreamHandler getExecuteStreamHandler(){ + protected ExecuteStreamHandler getExecuteStreamHandler() { if (this.executeStreamHandler == null) { setExecuteStreamHandler(new PumpStreamHandler(getOutputStream(), @@ -197,12 +197,12 @@ public abstract class AbstractCvsTask extends Task { } - protected void setOutputStream(OutputStream outputStream){ + protected void setOutputStream(OutputStream outputStream) { this.outputStream = outputStream; } - protected OutputStream getOutputStream(){ + protected OutputStream getOutputStream() { if (this.outputStream == null) { @@ -224,12 +224,12 @@ public abstract class AbstractCvsTask extends Task { return this.outputStream; } - protected void setErrorStream(OutputStream errorStream){ + protected void setErrorStream(OutputStream errorStream) { this.errorStream = errorStream; } - protected OutputStream getErrorStream(){ + protected OutputStream getErrorStream() { if (this.errorStream == null) { diff --git a/src/main/org/apache/tools/ant/taskdefs/Ant.java b/src/main/org/apache/tools/ant/taskdefs/Ant.java index b608996ff..cacfb66ed 100644 --- a/src/main/org/apache/tools/ant/taskdefs/Ant.java +++ b/src/main/org/apache/tools/ant/taskdefs/Ant.java @@ -535,7 +535,9 @@ public class Ant extends Task { public static class Reference extends org.apache.tools.ant.types.Reference { - public Reference() {super();} + public Reference() { + super(); + } private String targetid = null; diff --git a/src/main/org/apache/tools/ant/taskdefs/AntStructure.java b/src/main/org/apache/tools/ant/taskdefs/AntStructure.java index 1bf8af185..589876b88 100644 --- a/src/main/org/apache/tools/ant/taskdefs/AntStructure.java +++ b/src/main/org/apache/tools/ant/taskdefs/AntStructure.java @@ -83,7 +83,6 @@ import java.io.IOException; * * @ant.task category="xml" */ - public class AntStructure extends Task { private final String lSep = System.getProperty("line.separator"); @@ -103,6 +102,11 @@ public class AntStructure extends Task { this.output = output; } + /** + * Build the antstructure DTD. + * + * @exception BuildException if the DTD cannot be written. + */ public void execute() throws BuildException { if (output == null) { diff --git a/src/main/org/apache/tools/ant/taskdefs/CVSPass.java b/src/main/org/apache/tools/ant/taskdefs/CVSPass.java index efba52bd2..11ea5c6f7 100644 --- a/src/main/org/apache/tools/ant/taskdefs/CVSPass.java +++ b/src/main/org/apache/tools/ant/taskdefs/CVSPass.java @@ -106,6 +106,9 @@ public class CVSPass extends Task { 243, 233, 253, 240, 194, 250, 191, 155, 142, 137, 245, 235, 163, 242, 178, 152 }; + /** + * Create a CVS task using the default cvspass file location. + */ public CVSPass(){ passFile = new File(System.getProperty("user.home") + "/.cvspass"); } diff --git a/src/main/org/apache/tools/ant/taskdefs/Copy.java b/src/main/org/apache/tools/ant/taskdefs/Copy.java index 8f8129b69..773546a73 100644 --- a/src/main/org/apache/tools/ant/taskdefs/Copy.java +++ b/src/main/org/apache/tools/ant/taskdefs/Copy.java @@ -121,6 +121,9 @@ public class Copy extends Task { private FileUtils fileUtils; private String encoding = null; + /** + * Copy task constructor. + */ public Copy() { fileUtils = FileUtils.newFileUtils(); } diff --git a/src/main/org/apache/tools/ant/taskdefs/Ear.java b/src/main/org/apache/tools/ant/taskdefs/Ear.java index b1801ac4b..c7e61a679 100644 --- a/src/main/org/apache/tools/ant/taskdefs/Ear.java +++ b/src/main/org/apache/tools/ant/taskdefs/Ear.java @@ -76,6 +76,9 @@ public class Ear extends Jar { private File deploymentDescriptor; private boolean descriptorAdded; + /** + * Create an Ear task. + */ public Ear() { super(); archiveType = "ear"; diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/DefaultCompilerAdapter.java b/src/main/org/apache/tools/ant/taskdefs/compilers/DefaultCompilerAdapter.java index 8401e76d5..c8607618a 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/DefaultCompilerAdapter.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/DefaultCompilerAdapter.java @@ -114,6 +114,12 @@ public abstract class DefaultCompilerAdapter implements CompilerAdapter { private FileUtils fileUtils = FileUtils.newFileUtils(); + /** + * Set the Javac instance which contains the configured compilation + * attributes. + * + * @param attributes a configured Javac task. + */ public void setJavac(Javac attributes) { this.attributes = attributes; src = attributes.getSrcdir(); @@ -138,6 +144,11 @@ public abstract class DefaultCompilerAdapter implements CompilerAdapter { memoryMaximumSize = attributes.getMemoryMaximumSize(); } + /** + * Get the Javac task instance associated with this compiler adapter + * + * @return the configured Javac task instance used by this adapter. + */ public Javac getJavac() { return attributes; } diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/Javac12.java b/src/main/org/apache/tools/ant/taskdefs/compilers/Javac12.java index 2d23c5475..d124ecdc8 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/Javac12.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/Javac12.java @@ -79,6 +79,11 @@ import java.lang.reflect.Method; */ public class Javac12 extends DefaultCompilerAdapter { + /** + * Run the compilation. + * + * @exception BuildException if the compilation has problems. + */ public boolean execute() throws BuildException { attributes.log("Using classic compiler", Project.MSG_VERBOSE); Commandline cmd = setupJavacCommand(true); diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/Javac13.java b/src/main/org/apache/tools/ant/taskdefs/compilers/Javac13.java index d5efb7960..6202ac9e8 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/Javac13.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/Javac13.java @@ -82,6 +82,11 @@ public class Javac13 extends DefaultCompilerAdapter { */ private static final int MODERN_COMPILER_SUCCESS = 0; + /** + * Run the compilation. + * + * @exception BuildException if the compilation has problems. + */ public boolean execute() throws BuildException { attributes.log("Using modern compiler", Project.MSG_VERBOSE); Commandline cmd = setupModernJavacCommand(); diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/Jvc.java b/src/main/org/apache/tools/ant/taskdefs/compilers/Jvc.java index d782807ce..d0b89b7f7 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/Jvc.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/Jvc.java @@ -73,6 +73,11 @@ import org.apache.tools.ant.types.Commandline; */ public class Jvc extends DefaultCompilerAdapter { + /** + * Run the compilation. + * + * @exception BuildException if the compilation has problems. + */ public boolean execute() throws BuildException { attributes.log("Using jvc compiler", Project.MSG_VERBOSE); diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/Kjc.java b/src/main/org/apache/tools/ant/taskdefs/compilers/Kjc.java index cbecdd1a4..776187924 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/Kjc.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/Kjc.java @@ -74,6 +74,11 @@ import java.lang.reflect.Method; */ public class Kjc extends DefaultCompilerAdapter { + /** + * Run the compilation. + * + * @exception BuildException if the compilation has problems. + */ public boolean execute() throws BuildException { attributes.log("Using kjc compiler", Project.MSG_VERBOSE); Commandline cmd = setupKjcCommand(); diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/ejb/Ejbc.java b/src/main/org/apache/tools/ant/taskdefs/optional/ejb/Ejbc.java index 5f615521e..e5d55cbc1 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/ejb/Ejbc.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/ejb/Ejbc.java @@ -65,7 +65,7 @@ import java.io.File; /** * Build EJB support classes using Weblogic's ejbc tool from a directory containing * a set of deployment descriptors. - + * * * @author Conor MacNeill, Cortex ebusiness Pty Limited */ diff --git a/src/main/org/apache/tools/ant/types/Path.java b/src/main/org/apache/tools/ant/types/Path.java index dc5169023..2e7900865 100644 --- a/src/main/org/apache/tools/ant/types/Path.java +++ b/src/main/org/apache/tools/ant/types/Path.java @@ -100,6 +100,7 @@ public class Path extends DataType implements Cloneable { private Vector elements; + /** The system classspath as a Path object */ public static Path systemClasspath = new Path(null, System.getProperty("java.class.path")); diff --git a/src/main/org/apache/tools/ant/types/RegularExpression.java b/src/main/org/apache/tools/ant/types/RegularExpression.java index afa891079..377ab4525 100644 --- a/src/main/org/apache/tools/ant/types/RegularExpression.java +++ b/src/main/org/apache/tools/ant/types/RegularExpression.java @@ -97,6 +97,7 @@ import org.apache.tools.ant.util.regexp.RegexpFactory; * @ant.datatype name="regexp" */ public class RegularExpression extends DataType { + /** Name of this data type */ public static final String DATA_TYPE_NAME = "regexp"; // The regular expression factory diff --git a/src/main/org/apache/tools/ant/types/Substitution.java b/src/main/org/apache/tools/ant/types/Substitution.java index 7c701e113..b1f64ba3d 100644 --- a/src/main/org/apache/tools/ant/types/Substitution.java +++ b/src/main/org/apache/tools/ant/types/Substitution.java @@ -71,6 +71,7 @@ import org.apache.tools.ant.Project; * @author Matthew Inger mattinger@mindless.com */ public class Substitution extends DataType { + /** The name of this data type */ public static final String DATA_TYPE_NAME = "substitition"; private String expression; diff --git a/src/main/org/apache/tools/tar/TarOutputStream.java b/src/main/org/apache/tools/tar/TarOutputStream.java index e7cb8bb52..b9d602c11 100644 --- a/src/main/org/apache/tools/tar/TarOutputStream.java +++ b/src/main/org/apache/tools/tar/TarOutputStream.java @@ -71,8 +71,13 @@ import java.io.IOException; * @author Timothy Gerard Endres time@ice.com */ public class TarOutputStream extends FilterOutputStream { + /** Fail if a long file name is required in the archive. */ public static final int LONGFILE_ERROR = 0; + + /** Long paths will be truncated in the archive. */ public static final int LONGFILE_TRUNCATE = 1; + + /** GNU tar extensions are used to store long file names in the archive. */ public static final int LONGFILE_GNU = 2; protected boolean debug;