Skip to content

Commit

Permalink
Javadoc: Add missing @param
Browse files Browse the repository at this point in the history
  • Loading branch information
garydgregory committed Nov 11, 2024
1 parent be60e48 commit 75898bc
Show file tree
Hide file tree
Showing 22 changed files with 41 additions and 27 deletions.
2 changes: 1 addition & 1 deletion src/main/java/org/apache/commons/io/file/PathFilter.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public interface PathFilter {
* Tests whether or not to include the specified Path in a result.
*
* @param path The Path to test.
* @param attributes the file's basic attributes (TODO may be null).
* @param attributes the path's basic attributes (may be null).
* @return a FileVisitResult
*/
FileVisitResult accept(Path path, BasicFileAttributes attributes);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,9 @@ public boolean accept(final File file) {
* If last modification time equals cutoff and newer files are required, file <b>IS NOT</b> selected. If last
* modification time equals cutoff and older files are required, file <b>IS</b> selected.
* </p>
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file name matches
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,9 @@ public boolean accept(final File file) {

/**
* Checks to see if the file can be executed.
* @param file the File to check.
*
* @param file the File to check.
* @param attributes the path's basic attributes (may be null).
* @return {@code true} if the file can be executed, otherwise {@code false}.
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,9 @@ public boolean accept(final File file) {

/**
* Checks to see if the file can be read.
* @param file the File to check.
*
* @param file the File to check.
* @param attributes the path's basic attributes (may be null).
* @return {@code true} if the file can be read, otherwise {@code false}.
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,9 @@ public boolean accept(final File file) {

/**
* Checks to see if the file can be written to.
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return {@code true} if the file can be written to, otherwise {@code false}.
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,9 @@ public boolean accept(final File file) {

/**
* Checks to see if the file is a directory.
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file is a directory
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,9 @@ public boolean accept(final File file) {

/**
* Checks to see if the file is empty.
* @param file the file or directory to check
*
* @param file the file or directory to check
* @param attributes the path's basic attributes (may be null).
* @return {@code true} if the file or directory is <em>empty</em>, otherwise {@code false}.
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public boolean accept(final File dir, final String name) {
* Returns false.
*
* @param file the file to check (ignored)
*
* @param attributes the path's basic attributes (may be null).
* @return false
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,9 @@ public boolean accept(final File file) {

/**
* Checks to see if the file is a file.
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file is a file
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,10 @@ public boolean accept(final File file) {

/**
* Checks to see if the file is hidden.
* @param file the File to check
*
* @return {@code true} if the file is
* <em>hidden</em>, otherwise {@code false}.
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return {@code true} if the file is <em>hidden</em>, otherwise {@code false}.
* @since 2.9.0
*/
@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ public interface IOFileFilter extends FileFilter, FilenameFilter, PathFilter, Pa
* Checks to see if a Path should be accepted by this filter.
*
* @param path the Path to check.
* @param attributes the path's basic attributes (may be null).
* @return true if this path matches the test.
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,13 +276,13 @@ public boolean accept(final File file) {
* Accepts the provided file if the file contains the file filter's magic
* number at the specified offset.
* </p>
*
* <p>
* If any {@link IOException}s occur while reading the file, the file will
* be rejected.
*
* </p>
* @param file the file to accept or reject.
*
* @param attributes the path's basic attributes (may be null).
* @return {@code true} if the file contains the filter's magic number
* at the specified offset, {@code false} otherwise.
* @since 2.9.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,9 @@ public boolean accept(final File dir, final String name) {

/**
* Checks to see if the file name matches.
* @param path the File to check
*
* @param path the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file name matches
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,9 @@ public boolean accept(final File file, final String name) {

/**
* Returns the logical NOT of the underlying filter's return value for the same File.
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the filter returns false
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,9 @@ public boolean accept(final File file, final String name) {

/**
* Checks to see if the file name starts with the prefix.
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file name starts with one of our prefixes
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ public boolean accept(final File dir, final String name) {
* Checks to see if the file name matches one of the regular expressions.
*
* @param path the path
* @param attributes the path attributes
* @param attributes the path's basic attributes (may be null).
* @return true if the file name matches one of the regular expressions
*/
@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,13 +130,12 @@ private boolean accept(final long length) {
/**
* Checks to see if the size of the file is favorable.
* <p>
* If size equals threshold and smaller files are required,
* file <b>IS NOT</b> selected.
* If size equals threshold and larger files are required,
* file <b>IS</b> selected.
* If size equals threshold and smaller files are required, file <b>IS NOT</b> selected. If size equals threshold and larger files are required, file
* <b>IS</b> selected.
* </p>
* @param file the File to check
*
* @param file the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file name matches
*/
@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,9 @@ public boolean accept(final File file, final String name) {

/**
* Checks to see if the file name ends with the suffix.
* @param path the File to check
*
* @param path the File to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file name ends with one of our suffixes
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ public boolean accept(final File file) {
* Checks to see if the file is a symbolic link.
*
* @param path the File Path to check
* @param attributes the path's basic attributes (may be null).
* @return {@code onAccept} from {@link #SymbolicLinkFileFilter(FileVisitResult, FileVisitResult)} if the file exists and is a symbolic link to either
* another file or a directory; returns {@code onReject} otherwise.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,9 @@ public boolean accept(final File dir, final String name) {

/**
* Returns true.
* @param file the file to check (ignored)
*
* @param file the file to check (ignored)
* @param attributes the path's basic attributes (may be null).
* @return true
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ public boolean accept(final File dir, final String name) {
* Checks to see if the file name matches one of the wildcards.
*
* @param path the file to check
*
* @param attributes the path's basic attributes (may be null).
* @return true if the file name matches one of the wildcards.
* @since 2.9.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,9 @@ public boolean accept(final File dir, final String name) {

/**
* Checks to see if the file name matches one of the wildcards.
* @param path the file to check
*
* @param path the file to check
* @param attributes the path's basic attributes (may be null).
* @return true if the file name matches one of the wildcards
* @since 2.9.0
*/
Expand Down

0 comments on commit 75898bc

Please sign in to comment.