diff --git a/src/main/org/apache/tools/ant/BuildListener.java b/src/main/org/apache/tools/ant/BuildListener.java index 1f4f5918d..3ec1df486 100644 --- a/src/main/org/apache/tools/ant/BuildListener.java +++ b/src/main/org/apache/tools/ant/BuildListener.java @@ -68,7 +68,7 @@ public interface BuildListener extends EventListener { /** * Fired before any targets are started. */ - public void buildStarted(BuildEvent event); + void buildStarted(BuildEvent event); /** * Fired after the last target has finished. This event @@ -76,14 +76,14 @@ public interface BuildListener extends EventListener { * * @see BuildEvent#getException() */ - public void buildFinished(BuildEvent event); + void buildFinished(BuildEvent event); /** * Fired when a target is started. * * @see BuildEvent#getTarget() */ - public void targetStarted(BuildEvent event); + void targetStarted(BuildEvent event); /** * Fired when a target has finished. This event will @@ -91,14 +91,14 @@ public interface BuildListener extends EventListener { * * @see BuildEvent#getException() */ - public void targetFinished(BuildEvent event); + void targetFinished(BuildEvent event); /** * Fired when a task is started. * * @see BuildEvent#getTask() */ - public void taskStarted(BuildEvent event); + void taskStarted(BuildEvent event); /** * Fired when a task has finished. This event will still @@ -106,7 +106,7 @@ public interface BuildListener extends EventListener { * * @see BuildEvent#getException() */ - public void taskFinished(BuildEvent event); + void taskFinished(BuildEvent event); /** * Fired whenever a message is logged. @@ -114,6 +114,5 @@ public interface BuildListener extends EventListener { * @see BuildEvent#getMessage() * @see BuildEvent#getPriority() */ - public void messageLogged(BuildEvent event); - -} \ No newline at end of file + void messageLogged(BuildEvent event); +} diff --git a/src/main/org/apache/tools/ant/BuildLogger.java b/src/main/org/apache/tools/ant/BuildLogger.java index 96c8adb50..85f289cfc 100644 --- a/src/main/org/apache/tools/ant/BuildLogger.java +++ b/src/main/org/apache/tools/ant/BuildLogger.java @@ -77,14 +77,14 @@ public interface BuildLogger extends BuildListener { * * @param level the logging level for the logger. */ - public void setMessageOutputLevel(int level); + void setMessageOutputLevel(int level); /** * Set the output stream to which this logger is to send its output. * * @param output the output stream for the logger. */ - public void setOutputPrintStream(PrintStream output); + void setOutputPrintStream(PrintStream output); /** * Set this logger to produce emacs (and other editor) friendly output. @@ -92,13 +92,12 @@ public interface BuildLogger extends BuildListener { * @param emacsMode true if output is to be unadorned so that emacs and other * editors can parse files names, etc. */ - public void setEmacsMode(boolean emacsMode); + void setEmacsMode(boolean emacsMode); /** * Set the output stream to which this logger is to send error messages. * * @param err the error stream for the logger. */ - public void setErrorPrintStream(PrintStream err); - + void setErrorPrintStream(PrintStream err); } diff --git a/src/main/org/apache/tools/ant/FileScanner.java b/src/main/org/apache/tools/ant/FileScanner.java index f973ac0e4..bf08c0246 100644 --- a/src/main/org/apache/tools/ant/FileScanner.java +++ b/src/main/org/apache/tools/ant/FileScanner.java @@ -64,14 +64,14 @@ public interface FileScanner { * Adds an array with default exclusions to the current exclusions set. * */ - public void addDefaultExcludes(); + void addDefaultExcludes(); /** * Gets the basedir that is used for scanning. This is the directory that * is scanned recursively. * * @return the basedir that is used for scanning */ - public File getBasedir(); + File getBasedir(); /** * Get the names of the directories that matched at least one of the include * patterns, an matched also at least one of the exclude patterns. @@ -79,7 +79,7 @@ public interface FileScanner { * * @return the names of the directories */ - public String[] getExcludedDirectories(); + String[] getExcludedDirectories(); /** * Get the names of the files that matched at least one of the include * patterns, an matched also at least one of the exclude patterns. @@ -87,7 +87,7 @@ public interface FileScanner { * * @return the names of the files */ - public String[] getExcludedFiles(); + String[] getExcludedFiles(); /** * Get the names of the directories that matched at least one of the include * patterns, an matched none of the exclude patterns. @@ -95,7 +95,7 @@ public interface FileScanner { * * @return the names of the directories */ - public String[] getIncludedDirectories(); + String[] getIncludedDirectories(); /** * Get the names of the files that matched at least one of the include * patterns, an matched none of the exclude patterns. @@ -103,7 +103,7 @@ public interface FileScanner { * * @return the names of the files */ - public String[] getIncludedFiles(); + String[] getIncludedFiles(); /** * Get the names of the directories that matched at none of the include * patterns. @@ -111,45 +111,45 @@ public interface FileScanner { * * @return the names of the directories */ - public String[] getNotIncludedDirectories(); + String[] getNotIncludedDirectories(); /** * Get the names of the files that matched at none of the include patterns. * The names are relative to the basedir. * * @return the names of the files */ - public String[] getNotIncludedFiles(); + String[] getNotIncludedFiles(); /** * Scans the base directory for files that match at least one include * pattern, and don't match any exclude patterns. * * @exception IllegalStateException when basedir was set incorrecly */ - public void scan(); + void scan(); /** * Sets the basedir for scanning. This is the directory that is scanned * recursively. * * @param basedir the (non-null) basedir for scanning */ - public void setBasedir(String basedir); + void setBasedir(String basedir); /** * Sets the basedir for scanning. This is the directory that is scanned * recursively. * * @param basedir the basedir for scanning */ - public void setBasedir(File basedir); + void setBasedir(File basedir); /** * Sets the set of exclude patterns to use. * * @param excludes list of exclude patterns */ - public void setExcludes(String[] excludes); + void setExcludes(String[] excludes); /** * Sets the set of include patterns to use. * * @param includes list of include patterns */ - public void setIncludes(String[] includes); + void setIncludes(String[] includes); } diff --git a/src/main/org/apache/tools/ant/IntrospectionHelper.java b/src/main/org/apache/tools/ant/IntrospectionHelper.java index 4d2947867..df7976118 100644 --- a/src/main/org/apache/tools/ant/IntrospectionHelper.java +++ b/src/main/org/apache/tools/ant/IntrospectionHelper.java @@ -629,17 +629,17 @@ public class IntrospectionHelper implements BuildListener { } private interface NestedCreator { - public Object create(Object parent) + Object create(Object parent) throws InvocationTargetException, IllegalAccessException, InstantiationException; } private interface NestedStorer { - public void store(Object parent, Object child) + void store(Object parent, Object child) throws InvocationTargetException, IllegalAccessException, InstantiationException; } private interface AttributeSetter { - public void set(Project p, Object parent, String value) + void set(Project p, Object parent, String value) throws InvocationTargetException, IllegalAccessException, BuildException; } diff --git a/src/main/org/apache/tools/ant/taskdefs/ExecuteStreamHandler.java b/src/main/org/apache/tools/ant/taskdefs/ExecuteStreamHandler.java index 1025fb7a8..ac9bfef5a 100644 --- a/src/main/org/apache/tools/ant/taskdefs/ExecuteStreamHandler.java +++ b/src/main/org/apache/tools/ant/taskdefs/ExecuteStreamHandler.java @@ -72,29 +72,29 @@ public interface ExecuteStreamHandler { * @param os output stream to write to the standard input stream of the * subprocess */ - public void setProcessInputStream(OutputStream os) throws IOException; + void setProcessInputStream(OutputStream os) throws IOException; /** * Install a handler for the error stream of the subprocess. * * @param is input stream to read from the error stream from the subprocess */ - public void setProcessErrorStream(InputStream is) throws IOException; + void setProcessErrorStream(InputStream is) throws IOException; /** * Install a handler for the output stream of the subprocess. * * @param is input stream to read from the error stream from the subprocess */ - public void setProcessOutputStream(InputStream is) throws IOException; + void setProcessOutputStream(InputStream is) throws IOException; /** * Start handling of the streams. */ - public void start() throws IOException; + void start() throws IOException; /** * Stop handling of the streams - will not be restarted. */ - public void stop(); + void stop(); } diff --git a/src/main/org/apache/tools/ant/taskdefs/XSLTLiaison.java b/src/main/org/apache/tools/ant/taskdefs/XSLTLiaison.java index 4325f4290..231b82e23 100644 --- a/src/main/org/apache/tools/ant/taskdefs/XSLTLiaison.java +++ b/src/main/org/apache/tools/ant/taskdefs/XSLTLiaison.java @@ -76,13 +76,13 @@ public interface XSLTLiaison { * case since most parsers for now incorrectly makes no difference * between it.. and users also have problem with that :) */ - public final static String FILE_PROTOCOL_PREFIX = "file:///"; + String FILE_PROTOCOL_PREFIX = "file:///"; /** * set the stylesheet to use for the transformation. * @param stylesheet the stylesheet to be used for transformation. */ - public void setStylesheet(File stylesheet) throws Exception; + void setStylesheet(File stylesheet) throws Exception; /** * Add a parameter to be set during the XSL transformation. @@ -90,7 +90,7 @@ public interface XSLTLiaison { * @param expression the parameter value as an expression string. * @throws Exception thrown if any problems happens. */ - public void addParam(String name, String expression) throws Exception; + void addParam(String name, String expression) throws Exception; /** * Perform the transformation of a file into another. @@ -99,6 +99,6 @@ public interface XSLTLiaison { * @throws Exception thrown if any problems happens. * @see #setStylesheet(File) */ - public void transform(File infile, File outfile) throws Exception; + void transform(File infile, File outfile) throws Exception; } //-- XSLTLiaison diff --git a/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapter.java b/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapter.java index 82c79fd08..8e6d8e0c5 100644 --- a/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapter.java +++ b/src/main/org/apache/tools/ant/taskdefs/compilers/CompilerAdapter.java @@ -75,12 +75,12 @@ public interface CompilerAdapter { /** * Sets the compiler attributes, which are stored in the Javac task. */ - public void setJavac( Javac attributes ); + void setJavac( Javac attributes ); /** * Executes the task. * * @return has the compilation been successful */ - public boolean execute() throws BuildException; + boolean execute() throws BuildException; } diff --git a/src/main/org/apache/tools/ant/taskdefs/condition/Condition.java b/src/main/org/apache/tools/ant/taskdefs/condition/Condition.java index a2028d375..62f3b85ce 100644 --- a/src/main/org/apache/tools/ant/taskdefs/condition/Condition.java +++ b/src/main/org/apache/tools/ant/taskdefs/condition/Condition.java @@ -66,6 +66,6 @@ public interface Condition { /** * Is this condition true? */ - public boolean eval() throws BuildException; + boolean eval() throws BuildException; } diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/depend/ClassFileIterator.java b/src/main/org/apache/tools/ant/taskdefs/optional/depend/ClassFileIterator.java index 5bae20549..7889a31fe 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/depend/ClassFileIterator.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/depend/ClassFileIterator.java @@ -56,5 +56,5 @@ package org.apache.tools.ant.taskdefs.optional.depend; public interface ClassFileIterator { - public ClassFile getNextClassFile(); + ClassFile getNextClassFile(); } diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/ejb/EJBDeploymentTool.java b/src/main/org/apache/tools/ant/taskdefs/optional/ejb/EJBDeploymentTool.java index 978abf0be..16440044a 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/ejb/EJBDeploymentTool.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/ejb/EJBDeploymentTool.java @@ -70,22 +70,22 @@ public interface EJBDeploymentTool { * @param descriptorFilename the name of the deployment descriptor * @param saxParser a SAX parser which can be used to parse the deployment descriptor. */ - public void processDescriptor(String descriptorFilename, SAXParser saxParser) + void processDescriptor(String descriptorFilename, SAXParser saxParser) throws BuildException; /** * Called to validate that the tool parameters have been configured. * */ - public void validateConfigured() throws BuildException; + void validateConfigured() throws BuildException; /** * Set the task which owns this tool */ - public void setTask(Task task); + void setTask(Task task); /** * Configure this tool for use in the ejbjar task. */ - public void configure(EjbJar.Config config); -} \ No newline at end of file + void configure(EjbJar.Config config); +} diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/jsp/compilers/CompilerAdapter.java b/src/main/org/apache/tools/ant/taskdefs/optional/jsp/compilers/CompilerAdapter.java index 5aac85bb8..e03f0cbca 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/jsp/compilers/CompilerAdapter.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/jsp/compilers/CompilerAdapter.java @@ -75,12 +75,12 @@ public interface CompilerAdapter { /** * Sets the compiler attributes, which are stored in the Jspc task. */ - public void setJspc( JspC attributes ); + void setJspc( JspC attributes ); /** * Executes the task. * * @return has the compilation been successful */ - public boolean execute() throws BuildException; + boolean execute() throws BuildException; } diff --git a/src/main/org/apache/tools/ant/taskdefs/rmic/RmicAdapter.java b/src/main/org/apache/tools/ant/taskdefs/rmic/RmicAdapter.java index 7e044b032..608cfe88a 100644 --- a/src/main/org/apache/tools/ant/taskdefs/rmic/RmicAdapter.java +++ b/src/main/org/apache/tools/ant/taskdefs/rmic/RmicAdapter.java @@ -78,23 +78,23 @@ public interface RmicAdapter { /** * Sets the rmic attributes, which are stored in the Rmic task. */ - public void setRmic( Rmic attributes ); + void setRmic( Rmic attributes ); /** * Executes the task. * * @return has the compilation been successful */ - public boolean execute() throws BuildException; + boolean execute() throws BuildException; /** * Maps source class files to the files generated by this rmic * implementation. */ - public FileNameMapper getMapper(); + FileNameMapper getMapper(); /** * The CLASSPATH this rmic process will use. */ - public Path getClasspath(); + Path getClasspath(); } diff --git a/src/main/org/apache/tools/ant/util/FileNameMapper.java b/src/main/org/apache/tools/ant/util/FileNameMapper.java index 5a732ac41..2ad493f7f 100644 --- a/src/main/org/apache/tools/ant/util/FileNameMapper.java +++ b/src/main/org/apache/tools/ant/util/FileNameMapper.java @@ -71,12 +71,12 @@ public interface FileNameMapper { /** * Sets the from part of the transformation rule. */ - public void setFrom(String from); + void setFrom(String from); /** * Sets the to part of the transformation rule. */ - public void setTo(String to); + void setTo(String to); /** * Returns an array containing the target filename(s) for the @@ -89,5 +89,5 @@ public interface FileNameMapper { * @param sourceFileName the name of the source file relative to * some given basedirectory. */ - public String[] mapFileName(String sourceFileName); + String[] mapFileName(String sourceFileName); } diff --git a/src/main/org/apache/tools/ant/util/regexp/RegexpMatcher.java b/src/main/org/apache/tools/ant/util/regexp/RegexpMatcher.java index 8591f8358..398a48355 100644 --- a/src/main/org/apache/tools/ant/util/regexp/RegexpMatcher.java +++ b/src/main/org/apache/tools/ant/util/regexp/RegexpMatcher.java @@ -67,17 +67,17 @@ public interface RegexpMatcher { /** * Set the regexp pattern from the String description. */ - public void setPattern(String pattern) throws BuildException; + void setPattern(String pattern) throws BuildException; /** * Get a String representation of the regexp pattern */ - public String getPattern(); + String getPattern(); /** * Does the given argument match the pattern? */ - public boolean matches(String argument); + boolean matches(String argument); /** * Returns a Vector of matched groups found in the argument. @@ -85,5 +85,5 @@ public interface RegexpMatcher { *

Group 0 will be the full match, the rest are the * parenthesized subexpressions

. */ - public Vector getGroups(String argument); + Vector getGroups(String argument); } diff --git a/src/main/org/apache/tools/tar/TarConstants.java b/src/main/org/apache/tools/tar/TarConstants.java index fe4a69959..ae9a3b352 100644 --- a/src/main/org/apache/tools/tar/TarConstants.java +++ b/src/main/org/apache/tools/tar/TarConstants.java @@ -71,121 +71,121 @@ public interface TarConstants { /** * The length of the name field in a header buffer. */ - public static final int NAMELEN = 100; + int NAMELEN = 100; /** * The length of the mode field in a header buffer. */ - public static final int MODELEN = 8; + int MODELEN = 8; /** * The length of the user id field in a header buffer. */ - public static final int UIDLEN = 8; + int UIDLEN = 8; /** * The length of the group id field in a header buffer. */ - public static final int GIDLEN = 8; + int GIDLEN = 8; /** * The length of the checksum field in a header buffer. */ - public static final int CHKSUMLEN = 8; + int CHKSUMLEN = 8; /** * The length of the size field in a header buffer. */ - public static final int SIZELEN = 12; + int SIZELEN = 12; /** * The length of the magic field in a header buffer. */ - public static final int MAGICLEN = 8; + int MAGICLEN = 8; /** * The length of the modification time field in a header buffer. */ - public static final int MODTIMELEN = 12; + int MODTIMELEN = 12; /** * The length of the user name field in a header buffer. */ - public static final int UNAMELEN = 32; + int UNAMELEN = 32; /** * The length of the group name field in a header buffer. */ - public static final int GNAMELEN = 32; + int GNAMELEN = 32; /** * The length of the devices field in a header buffer. */ - public static final int DEVLEN = 8; + int DEVLEN = 8; /** * LF_ constants represent the "link flag" of an entry, or more commonly, * the "entry type". This is the "old way" of indicating a normal file. */ - public static final byte LF_OLDNORM = 0; + byte LF_OLDNORM = 0; /** * Normal file type. */ - public static final byte LF_NORMAL = (byte) '0'; + byte LF_NORMAL = (byte) '0'; /** * Link file type. */ - public static final byte LF_LINK = (byte) '1'; + byte LF_LINK = (byte) '1'; /** * Symbolic link file type. */ - public static final byte LF_SYMLINK = (byte) '2'; + byte LF_SYMLINK = (byte) '2'; /** * Character device file type. */ - public static final byte LF_CHR = (byte) '3'; + byte LF_CHR = (byte) '3'; /** * Block device file type. */ - public static final byte LF_BLK = (byte) '4'; + byte LF_BLK = (byte) '4'; /** * Directory file type. */ - public static final byte LF_DIR = (byte) '5'; + byte LF_DIR = (byte) '5'; /** * FIFO (pipe) file type. */ - public static final byte LF_FIFO = (byte) '6'; + byte LF_FIFO = (byte) '6'; /** * Contiguous file type. */ - public static final byte LF_CONTIG = (byte) '7'; + byte LF_CONTIG = (byte) '7'; /** * The magic tag representing a POSIX tar archive. */ - public static final String TMAGIC = "ustar"; + String TMAGIC = "ustar"; /** * The magic tag representing a GNU tar archive. */ - public static final String GNU_TMAGIC = "ustar "; + String GNU_TMAGIC = "ustar "; /** * The namr of the GNU tar entry which contains a long name. */ - public static final String GNU_LONGLINK = "././@LongLink"; + String GNU_LONGLINK = "././@LongLink"; /** * Identifies the *next* file on the tape as having a long name. */ - public static final byte LF_GNUTYPE_LONGNAME = (byte) 'L'; + byte LF_GNUTYPE_LONGNAME = (byte) 'L'; } diff --git a/src/main/org/apache/tools/zip/UnixStat.java b/src/main/org/apache/tools/zip/UnixStat.java index cb04700c6..950084d8c 100644 --- a/src/main/org/apache/tools/zip/UnixStat.java +++ b/src/main/org/apache/tools/zip/UnixStat.java @@ -67,25 +67,25 @@ public interface UnixStat { * * @since 1.1 */ - public static final int PERM_MASK = 07777; + int PERM_MASK = 07777; /** * Indicates symbolic links. * * @since 1.1 */ - public static final int LINK_FLAG = 0120000; + int LINK_FLAG = 0120000; /** * Indicates plain files. * * @since 1.1 */ - public static final int FILE_FLAG = 0100000; + int FILE_FLAG = 0100000; /** * Indicates directories. * * @since 1.1 */ - public static final int DIR_FLAG = 040000; + int DIR_FLAG = 040000; // ---------------------------------------------------------- // somewhat arbitrary choices that are quite common for shared @@ -97,17 +97,17 @@ public interface UnixStat { * * @since 1.1 */ - public static final int DEFAULT_LINK_PERM = 0777; + int DEFAULT_LINK_PERM = 0777; /** * Default permissions for directories. * * @since 1.1 */ - public static final int DEFAULT_DIR_PERM = 0755; + int DEFAULT_DIR_PERM = 0755; /** * Default permissions for plain files. * * @since 1.1 */ - public static final int DEFAULT_FILE_PERM = 0644; + int DEFAULT_FILE_PERM = 0644; } diff --git a/src/main/org/apache/tools/zip/ZipExtraField.java b/src/main/org/apache/tools/zip/ZipExtraField.java index 034d55f8c..2742c7e00 100644 --- a/src/main/org/apache/tools/zip/ZipExtraField.java +++ b/src/main/org/apache/tools/zip/ZipExtraField.java @@ -75,7 +75,7 @@ public interface ZipExtraField { * * @since 1.1 */ - public ZipShort getHeaderId(); + ZipShort getHeaderId(); /** * Length of the extra field in the local file data - without @@ -83,7 +83,7 @@ public interface ZipExtraField { * * @since 1.1 */ - public ZipShort getLocalFileDataLength(); + ZipShort getLocalFileDataLength(); /** * Length of the extra field in the central directory - without @@ -91,7 +91,7 @@ public interface ZipExtraField { * * @since 1.1 */ - public ZipShort getCentralDirectoryLength(); + ZipShort getCentralDirectoryLength(); /** * The actual data to put into local file data - without Header-ID @@ -99,7 +99,7 @@ public interface ZipExtraField { * * @since 1.1 */ - public byte[] getLocalFileDataData(); + byte[] getLocalFileDataData(); /** * The actual data to put central directory - without Header-ID or @@ -107,13 +107,13 @@ public interface ZipExtraField { * * @since 1.1 */ - public byte[] getCentralDirectoryData(); + byte[] getCentralDirectoryData(); /** * Populate data from this array as if it was in local file data. * * @since 1.1 */ - public void parseFromLocalFileData(byte[] data, int offset, int length) + void parseFromLocalFileData(byte[] data, int offset, int length) throws ZipException; }