You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2020/05/04 14:29:36 UTC
[commons-io] branch master updated: Javadoc.
This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-io.git
The following commit(s) were added to refs/heads/master by this push:
new e997b9c Javadoc.
e997b9c is described below
commit e997b9c670fb1fee2ee0d44759c037c5d5815f6c
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Mon May 4 10:29:31 2020 -0400
Javadoc.
---
.../commons/io/monitor/FileAlterationMonitor.java | 23 ++++++------
.../commons/io/monitor/FileAlterationObserver.java | 41 +++++++++++-----------
2 files changed, 33 insertions(+), 31 deletions(-)
diff --git a/src/main/java/org/apache/commons/io/monitor/FileAlterationMonitor.java b/src/main/java/org/apache/commons/io/monitor/FileAlterationMonitor.java
index 17b8cb1..3be7fc6 100644
--- a/src/main/java/org/apache/commons/io/monitor/FileAlterationMonitor.java
+++ b/src/main/java/org/apache/commons/io/monitor/FileAlterationMonitor.java
@@ -36,14 +36,14 @@ public final class FileAlterationMonitor implements Runnable {
private volatile boolean running = false;
/**
- * Construct a monitor with a default interval of 10 seconds.
+ * Constructs a monitor with a default interval of 10 seconds.
*/
public FileAlterationMonitor() {
this(10000);
}
/**
- * Construct a monitor with the specified interval.
+ * Constructs a monitor with the specified interval.
*
* @param interval The amount of time in milliseconds to wait between
* checks of the file system
@@ -53,7 +53,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Construct a monitor with the specified interval and set of observers.
+ * Constructs a monitor with the specified interval and set of observers.
*
* @param interval The amount of time in milliseconds to wait between
* checks of the file system
@@ -69,7 +69,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Return the interval.
+ * Returns the interval.
*
* @return the interval
*/
@@ -78,7 +78,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Set the thread factory.
+ * Sets the thread factory.
*
* @param threadFactory the thread factory
*/
@@ -87,7 +87,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Add a file system observer to this monitor.
+ * Adds a file system observer to this monitor.
*
* @param observer The file system observer to add
*/
@@ -98,13 +98,14 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Remove a file system observer from this monitor.
+ * Removes a file system observer from this monitor.
*
* @param observer The file system observer to remove
*/
public void removeObserver(final FileAlterationObserver observer) {
if (observer != null) {
while (observers.remove(observer)) {
+ // empty
}
}
}
@@ -120,7 +121,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Start monitoring.
+ * Starts monitoring.
*
* @throws Exception if an error occurs initializing the observer
*/
@@ -141,7 +142,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Stop monitoring.
+ * Stops monitoring.
*
* @throws Exception if an error occurs initializing the observer
*/
@@ -150,7 +151,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Stop monitoring.
+ * Stops monitoring.
*
* @param stopInterval the amount of time in milliseconds to wait for the thread to finish.
* A value of zero will wait until the thread is finished (see {@link Thread#join(long)}).
@@ -174,7 +175,7 @@ public final class FileAlterationMonitor implements Runnable {
}
/**
- * Run.
+ * Runs this monitor.
*/
@Override
public void run() {
diff --git a/src/main/java/org/apache/commons/io/monitor/FileAlterationObserver.java b/src/main/java/org/apache/commons/io/monitor/FileAlterationObserver.java
index 9928af8..eff69a1 100644
--- a/src/main/java/org/apache/commons/io/monitor/FileAlterationObserver.java
+++ b/src/main/java/org/apache/commons/io/monitor/FileAlterationObserver.java
@@ -128,7 +128,7 @@ public class FileAlterationObserver implements Serializable {
private final Comparator<File> comparator;
/**
- * Construct an observer for the specified directory.
+ * Constructs an observer for the specified directory.
*
* @param directoryName the name of the directory to observe
*/
@@ -137,7 +137,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Construct an observer for the specified directory and file filter.
+ * Constructs an observer for the specified directory and file filter.
*
* @param directoryName the name of the directory to observe
* @param fileFilter The file filter or null if none
@@ -160,7 +160,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Construct an observer for the specified directory.
+ * Constructs an observer for the specified directory.
*
* @param directory the directory to observe
*/
@@ -169,7 +169,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Construct an observer for the specified directory and file filter.
+ * Constructs an observer for the specified directory and file filter.
*
* @param directory the directory to observe
* @param fileFilter The file filter or null if none
@@ -179,7 +179,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Construct an observer for the specified directory, file filter and
+ * Constructs an observer for the specified directory, file filter and
* file comparator.
*
* @param directory the directory to observe
@@ -191,7 +191,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Construct an observer for the specified directory, file filter and
+ * Constructs an observer for the specified directory, file filter and
* file comparator.
*
* @param rootEntry the root directory to observe
@@ -218,7 +218,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Return the directory being observed.
+ * Returns the directory being observed.
*
* @return the directory being observed
*/
@@ -227,7 +227,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Return the fileFilter.
+ * Returns the fileFilter.
*
* @return the fileFilter
* @since 2.1
@@ -237,7 +237,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Add a file system listener.
+ * Adds a file system listener.
*
* @param listener The file system listener
*/
@@ -248,13 +248,14 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Remove a file system listener.
+ * Removes a file system listener.
*
* @param listener The file system listener
*/
public void removeListener(final FileAlterationListener listener) {
if (listener != null) {
while (listeners.remove(listener)) {
+ // empty
}
}
}
@@ -269,7 +270,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Initialize the observer.
+ * Initializes the observer.
*
* @throws Exception if an error occurs
*/
@@ -289,7 +290,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Check whether the file and its children have been created, modified or deleted.
+ * Checks whether the file and its children have been created, modified or deleted.
*/
public void checkAndNotify() {
@@ -315,7 +316,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Compare two file lists for files which have been created, modified or deleted.
+ * Compares two file lists for files which have been created, modified or deleted.
*
* @param parent The parent entry
* @param previous The original list of files
@@ -348,7 +349,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Create a new file entry for the specified file.
+ * Creates a new file entry for the specified file.
*
* @param parent The parent file entry
* @param file The file to create an entry for
@@ -363,7 +364,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * List the files
+ * Lists the files
* @param file The file to list files for
* @param entry the parent entry
* @return The child files
@@ -378,7 +379,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Fire directory/file created events to the registered listeners.
+ * Fires directory/file created events to the registered listeners.
*
* @param entry The file entry
*/
@@ -397,7 +398,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Fire directory/file change events to the registered listeners.
+ * Fires directory/file change events to the registered listeners.
*
* @param entry The previous file system entry
* @param file The current file
@@ -415,7 +416,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Fire directory/file delete events to the registered listeners.
+ * Fires directory/file delete events to the registered listeners.
*
* @param entry The file entry
*/
@@ -430,7 +431,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * List the contents of a directory
+ * Lists the contents of a directory
*
* @param file The file to list the contents of
* @return the directory contents or a zero length array if
@@ -451,7 +452,7 @@ public class FileAlterationObserver implements Serializable {
}
/**
- * Provide a String representation of this observer.
+ * Returns a String representation of this observer.
*
* @return a String representation of this observer
*/