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 2019/08/09 21:14:09 UTC

[commons-io] branch master updated (88f75b8 -> 5ba8b48)

This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/commons-io.git.


    from 88f75b8  [IO-617] Add classes Added TaggedReader, ClosedReader and BrokenReader. #85.
     new 4bbdbfe  Remove trailing white spaces on all lines
     new b7ec4f7  Use final.
     new fa8525f  Remove redundant semicolons
     new 6bcf897  Remove redundant modifiers
     new d4f1fdd  Javadoc.
     new 5ba8b48  Checkstyle 2.17 -> 3.0.0.

The 6 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 pom.xml                                                    |  2 +-
 src/main/java/org/apache/commons/io/FileUtils.java         |  4 ++--
 src/main/java/org/apache/commons/io/IOExceptionList.java   | 14 +++++++-------
 .../java/org/apache/commons/io/IOIndexedException.java     |  7 +++++++
 .../java/org/apache/commons/io/input/TaggedReader.java     |  4 ++--
 .../commons/io/input/buffer/CircularBufferInputStream.java | 10 +++++-----
 .../apache/commons/io/input/buffer/CircularByteBuffer.java | 12 ++++++------
 .../commons/io/input/buffer/PeekableInputStream.java       |  8 ++++----
 .../apache/commons/io/output/FilterCollectionWriter.java   |  2 +-
 src/main/java/org/apache/commons/io/output/TeeWriter.java  |  2 +-
 .../commons/io/input/ClassLoaderObjectInputStreamTest.java |  2 +-
 .../org/apache/commons/io/input/CloseShieldReaderTest.java |  2 +-
 .../org/apache/commons/io/input/XmlStreamReaderTest.java   |  4 ++--
 .../io/serialization/ValidatingObjectInputStreamTest.java  |  2 +-
 14 files changed, 41 insertions(+), 34 deletions(-)


[commons-io] 01/06: Remove trailing white spaces on all lines

Posted by gg...@apache.org.
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

commit 4bbdbfed1d810e7558594aea59f2c819f95cbed3
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Aug 9 14:07:57 2019 -0400

    Remove trailing white spaces on all lines
---
 src/main/java/org/apache/commons/io/IOExceptionList.java          | 8 ++++----
 src/main/java/org/apache/commons/io/input/TaggedReader.java       | 4 ++--
 .../java/org/apache/commons/io/output/FilterCollectionWriter.java | 2 +-
 src/main/java/org/apache/commons/io/output/TeeWriter.java         | 2 +-
 4 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/main/java/org/apache/commons/io/IOExceptionList.java b/src/main/java/org/apache/commons/io/IOExceptionList.java
index f6aeec4..cdfffca 100644
--- a/src/main/java/org/apache/commons/io/IOExceptionList.java
+++ b/src/main/java/org/apache/commons/io/IOExceptionList.java
@@ -48,7 +48,7 @@ public class IOExceptionList extends IOException {
 
     /**
      * Gets the cause list.
-     * 
+     *
      * @param <T> type of exception to return.
      * @return The list of causes.
      */
@@ -58,7 +58,7 @@ public class IOExceptionList extends IOException {
 
     /**
      * Gets the cause list.
-     * 
+     *
      * @param <T> type of exception to return.
      * @param index index in the cause list.
      * @return The list of causes.
@@ -69,7 +69,7 @@ public class IOExceptionList extends IOException {
 
     /**
      * Gets the cause list.
-     * 
+     *
      * @param <T> type of exception to return.
      * @param index index in the cause list.
      * @param clazz type of exception to return.
@@ -81,7 +81,7 @@ public class IOExceptionList extends IOException {
 
     /**
      * Works around Throwable and Generics, may fail at runtime depending on the argument value.
-     * 
+     *
      * @param <T> type of exception to return.
      * @param clazz the target type
      * @return The list of causes.
diff --git a/src/main/java/org/apache/commons/io/input/TaggedReader.java b/src/main/java/org/apache/commons/io/input/TaggedReader.java
index 0227dd9..4711414 100644
--- a/src/main/java/org/apache/commons/io/input/TaggedReader.java
+++ b/src/main/java/org/apache/commons/io/input/TaggedReader.java
@@ -27,7 +27,7 @@ import org.apache.commons.io.TaggedIOException;
  * A reader decorator that tags potential exceptions so that the reader that caused the exception can easily be
  * identified. This is done by using the {@link TaggedIOException} class to wrap all thrown {@link IOException}s. See
  * below for an example of using this class.
- * 
+ *
  * <pre>
  * TaggedReader reader = new TaggedReader(...);
  * try {
@@ -47,7 +47,7 @@ import org.apache.commons.io.TaggedIOException;
  * Alternatively, the {@link #throwIfCauseOf(Throwable)} method can be used to let higher levels of code handle the
  * exception caused by this reader while other processing errors are being taken care of at this lower level.
  * </p>
- * 
+ *
  * <pre>
  * TaggedReader reader = new TaggedReader(...);
  * try {
diff --git a/src/main/java/org/apache/commons/io/output/FilterCollectionWriter.java b/src/main/java/org/apache/commons/io/output/FilterCollectionWriter.java
index ed9114c..2bdb607 100644
--- a/src/main/java/org/apache/commons/io/output/FilterCollectionWriter.java
+++ b/src/main/java/org/apache/commons/io/output/FilterCollectionWriter.java
@@ -40,7 +40,7 @@ import org.apache.commons.io.IOIndexedException;
  * The class {@link Writer} defines method signatures with {@code throws} {@link IOException}, which in this class are
  * actually {@link IOExceptionList} containing a list of {@link IOIndexedException}.
  * </p>
- * 
+ *
  * @since 2.7
  */
 public class FilterCollectionWriter extends Writer {
diff --git a/src/main/java/org/apache/commons/io/output/TeeWriter.java b/src/main/java/org/apache/commons/io/output/TeeWriter.java
index 3fc0168..e373bc1 100644
--- a/src/main/java/org/apache/commons/io/output/TeeWriter.java
+++ b/src/main/java/org/apache/commons/io/output/TeeWriter.java
@@ -26,7 +26,7 @@ import java.util.Collection;
  * <p>
  * This currently a only convenience class with the proper name "TeeWriter".
  * </p>
- * 
+ *
  * @since 2.7
  */
 public class TeeWriter extends ProxyCollectionWriter {


[commons-io] 02/06: Use final.

Posted by gg...@apache.org.
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

commit b7ec4f7e855ecb77c8bf42fdd97f123d4588edd2
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Aug 9 14:08:44 2019 -0400

    Use final.
---
 src/main/java/org/apache/commons/io/FileUtils.java           |  4 ++--
 src/main/java/org/apache/commons/io/IOExceptionList.java     |  6 +++---
 .../commons/io/input/buffer/CircularBufferInputStream.java   | 10 +++++-----
 .../apache/commons/io/input/buffer/CircularByteBuffer.java   | 12 ++++++------
 .../apache/commons/io/input/buffer/PeekableInputStream.java  |  8 ++++----
 .../org/apache/commons/io/input/CloseShieldReaderTest.java   |  2 +-
 6 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/src/main/java/org/apache/commons/io/FileUtils.java b/src/main/java/org/apache/commons/io/FileUtils.java
index c77e35a..6503eb3 100644
--- a/src/main/java/org/apache/commons/io/FileUtils.java
+++ b/src/main/java/org/apache/commons/io/FileUtils.java
@@ -1154,8 +1154,8 @@ public class FileUtils {
             throw new IOException("Destination '" + destFile + "' exists but is a directory");
         }
 
-        Path srcPath = srcFile.toPath();
-        Path destPath = destFile.toPath();
+        final Path srcPath = srcFile.toPath();
+        final Path destPath = destFile.toPath();
         final long newLastModifed = preserveFileDate ? srcFile.lastModified() : destFile.lastModified();
         Files.copy(srcPath, destPath, StandardCopyOption.REPLACE_EXISTING);
 
diff --git a/src/main/java/org/apache/commons/io/IOExceptionList.java b/src/main/java/org/apache/commons/io/IOExceptionList.java
index cdfffca..5cb2c74 100644
--- a/src/main/java/org/apache/commons/io/IOExceptionList.java
+++ b/src/main/java/org/apache/commons/io/IOExceptionList.java
@@ -40,7 +40,7 @@ public class IOExceptionList extends IOException {
      *
      * @param causeList a list of cause exceptions.
      */
-    public IOExceptionList(List<? extends Throwable> causeList) {
+    public IOExceptionList(final List<? extends Throwable> causeList) {
         super(String.format("%,d exceptions: %s", causeList == null ? 0 : causeList.size(), causeList),
                 causeList == null ? null : causeList.get(0));
         this.causeList = causeList == null ? Collections.emptyList() : causeList;
@@ -75,7 +75,7 @@ public class IOExceptionList extends IOException {
      * @param clazz type of exception to return.
      * @return The list of causes.
      */
-    public <T extends Throwable> T getCause(final int index, Class<T> clazz) {
+    public <T extends Throwable> T getCause(final int index, final Class<T> clazz) {
         return (T) causeList.get(index);
     }
 
@@ -86,7 +86,7 @@ public class IOExceptionList extends IOException {
      * @param clazz the target type
      * @return The list of causes.
      */
-    public <T extends Throwable> List<T> getCauseList(Class<T> clazz) {
+    public <T extends Throwable> List<T> getCauseList(final Class<T> clazz) {
         return (List<T>) causeList;
     }
 
diff --git a/src/main/java/org/apache/commons/io/input/buffer/CircularBufferInputStream.java b/src/main/java/org/apache/commons/io/input/buffer/CircularBufferInputStream.java
index 8d20de1..1ab8000 100644
--- a/src/main/java/org/apache/commons/io/input/buffer/CircularBufferInputStream.java
+++ b/src/main/java/org/apache/commons/io/input/buffer/CircularBufferInputStream.java
@@ -40,7 +40,7 @@ public class CircularBufferInputStream extends InputStream {
      * @param pBufferSize The size of the {@link CircularByteBuffer}, which is
      *                    used internally.
      */
-    public CircularBufferInputStream(InputStream pIn, int pBufferSize) {
+    public CircularBufferInputStream(final InputStream pIn, final int pBufferSize) {
         Objects.requireNonNull(pIn, "InputStream");
         if (pBufferSize <= 0) {
             throw new IllegalArgumentException("Invalid buffer size: " + pBufferSize);
@@ -57,7 +57,7 @@ public class CircularBufferInputStream extends InputStream {
      *
      * @param pIn The input stream, which is being buffered.
      */
-    public CircularBufferInputStream(InputStream pIn) {
+    public CircularBufferInputStream(final InputStream pIn) {
         this(pIn, 8192);
     }
 
@@ -91,7 +91,7 @@ public class CircularBufferInputStream extends InputStream {
      * @return true if the buffer has bytes
      * @throws IOException in case of an error while reading from the input stream.
      */
-    protected boolean haveBytes(int pNumber) throws IOException {
+    protected boolean haveBytes(final int pNumber) throws IOException {
         if (buffer.getCurrentNumberOfBytes() < pNumber) {
             fillBuffer();
         }
@@ -107,12 +107,12 @@ public class CircularBufferInputStream extends InputStream {
     }
 
     @Override
-    public int read(byte[] pBuffer) throws IOException {
+    public int read(final byte[] pBuffer) throws IOException {
         return read(pBuffer, 0, pBuffer.length);
     }
 
     @Override
-    public int read(byte[] pBuffer, int pOffset, int pLength) throws IOException {
+    public int read(final byte[] pBuffer, final int pOffset, final int pLength) throws IOException {
         Objects.requireNonNull(pBuffer, "Buffer");
         if (pOffset < 0) {
             throw new IllegalArgumentException("Offset must not be negative");
diff --git a/src/main/java/org/apache/commons/io/input/buffer/CircularByteBuffer.java b/src/main/java/org/apache/commons/io/input/buffer/CircularByteBuffer.java
index 95ca142..b15a737 100644
--- a/src/main/java/org/apache/commons/io/input/buffer/CircularByteBuffer.java
+++ b/src/main/java/org/apache/commons/io/input/buffer/CircularByteBuffer.java
@@ -34,7 +34,7 @@ public class CircularByteBuffer {
      *
      * @param pSize the size of buffer to create
      */
-    public CircularByteBuffer(int pSize) {
+    public CircularByteBuffer(final int pSize) {
         buffer = new byte[pSize];
         startOffset = 0;
         endOffset = 0;
@@ -82,7 +82,7 @@ public class CircularByteBuffer {
      *                                  of bytes. Use {@link #getCurrentNumberOfBytes()} to prevent this
      *                                  exception.
      */
-    public void read(byte[] pBuffer, int pOffset, int pLength) {
+    public void read(final byte[] pBuffer, final int pOffset, final int pLength) {
         Objects.requireNonNull(pBuffer);
         if (pOffset < 0 || pOffset >= pBuffer.length) {
             throw new IllegalArgumentException("Invalid offset: " + pOffset);
@@ -117,7 +117,7 @@ public class CircularByteBuffer {
      * @throws IllegalStateException The buffer is full. Use {@link #hasSpace()},
      *                               or {@link #getSpace()}, to prevent this exception.
      */
-    public void add(byte pByte) {
+    public void add(final byte pByte) {
         if (currentNumberOfBytes >= buffer.length) {
             throw new IllegalStateException("No space available");
         }
@@ -143,7 +143,7 @@ public class CircularByteBuffer {
      * @throws IllegalArgumentException Either of {@code pOffset}, or {@code pLength} is negative.
      * @throws NullPointerException     The byte array {@code pBuffer} is null.
      */
-    public boolean peek(byte[] pBuffer, int pOffset, int pLength) {
+    public boolean peek(final byte[] pBuffer, final int pOffset, final int pLength) {
         Objects.requireNonNull(pBuffer, "Buffer");
         if (pOffset < 0 || pOffset >= pBuffer.length) {
             throw new IllegalArgumentException("Invalid offset: " + pOffset);
@@ -179,7 +179,7 @@ public class CircularByteBuffer {
      * @throws IllegalArgumentException Either of {@code pOffset}, or {@code pLength} is negative.
      * @throws NullPointerException     The byte array {@code pBuffer} is null.
      */
-    public void add(byte[] pBuffer, int pOffset, int pLength) {
+    public void add(final byte[] pBuffer, final int pOffset, final int pLength) {
         Objects.requireNonNull(pBuffer, "Buffer");
         if (pOffset < 0 || pOffset >= pBuffer.length) {
             throw new IllegalArgumentException("Invalid offset: " + pOffset);
@@ -219,7 +219,7 @@ public class CircularByteBuffer {
      * @see #hasSpace()
      * @see #getSpace()
      */
-    public boolean hasSpace(int pBytes) {
+    public boolean hasSpace(final int pBytes) {
         return currentNumberOfBytes + pBytes <= buffer.length;
     }
 
diff --git a/src/main/java/org/apache/commons/io/input/buffer/PeekableInputStream.java b/src/main/java/org/apache/commons/io/input/buffer/PeekableInputStream.java
index feed9c1..891f138 100644
--- a/src/main/java/org/apache/commons/io/input/buffer/PeekableInputStream.java
+++ b/src/main/java/org/apache/commons/io/input/buffer/PeekableInputStream.java
@@ -35,7 +35,7 @@ public class PeekableInputStream extends CircularBufferInputStream {
      * @param pBufferSize The size of the {@link CircularByteBuffer}, which is
      *                    used internally.
      */
-    public PeekableInputStream(InputStream pIn, int pBufferSize) {
+    public PeekableInputStream(final InputStream pIn, final int pBufferSize) {
         super(pIn, pBufferSize);
     }
 
@@ -45,7 +45,7 @@ public class PeekableInputStream extends CircularBufferInputStream {
      *
      * @param pIn The input stream, which is being buffered.
      */
-    public PeekableInputStream(InputStream pIn) {
+    public PeekableInputStream(final InputStream pIn) {
         super(pIn);
     }
 
@@ -58,7 +58,7 @@ public class PeekableInputStream extends CircularBufferInputStream {
      * @return true if the next bytes are as given
      * @throws IOException Refilling the buffer failed.
      */
-    public boolean peek(byte[] pBuffer) throws IOException {
+    public boolean peek(final byte[] pBuffer) throws IOException {
         Objects.requireNonNull(pBuffer, "Buffer");
         if (pBuffer.length > bufferSize) {
             throw new IllegalArgumentException("Peek request size of " + pBuffer.length
@@ -80,7 +80,7 @@ public class PeekableInputStream extends CircularBufferInputStream {
      * @return true if the next bytes in the buffer are as given
      * @throws IOException if there is a problem calling fillBuffer()
      */
-    public boolean peek(byte[] pBuffer, int pOffset, int pLength) throws IOException {
+    public boolean peek(final byte[] pBuffer, final int pOffset, final int pLength) throws IOException {
         Objects.requireNonNull(pBuffer, "Buffer");
         if (pBuffer.length > bufferSize) {
             throw new IllegalArgumentException("Peek request size of " + pBuffer.length
diff --git a/src/test/java/org/apache/commons/io/input/CloseShieldReaderTest.java b/src/test/java/org/apache/commons/io/input/CloseShieldReaderTest.java
index 6c6d659..b609df9 100644
--- a/src/test/java/org/apache/commons/io/input/CloseShieldReaderTest.java
+++ b/src/test/java/org/apache/commons/io/input/CloseShieldReaderTest.java
@@ -49,7 +49,7 @@ public class CloseShieldReaderTest {
     public void testClose() throws IOException {
         shielded.close();
         verify(original, never()).close();
-        char[] cbuf = new char[10];
+        final char[] cbuf = new char[10];
         assertEquals("read(cbuf, off, len)", -1, shielded.read(cbuf, 0, 10));
         assertEquals("read(cbuf, off, len)", data.length(), original.read(cbuf, 0, 10));
         assertEquals(data, new String(cbuf, 0, data.length()));


[commons-io] 04/06: Remove redundant modifiers

Posted by gg...@apache.org.
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

commit 6bcf8971d5abf83103b325a41fb792c58ea2ac2c
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Aug 9 14:10:22 2019 -0400

    Remove redundant modifiers
---
 .../org/apache/commons/io/input/ClassLoaderObjectInputStreamTest.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/test/java/org/apache/commons/io/input/ClassLoaderObjectInputStreamTest.java b/src/test/java/org/apache/commons/io/input/ClassLoaderObjectInputStreamTest.java
index 12ffdc6..34b93cd 100644
--- a/src/test/java/org/apache/commons/io/input/ClassLoaderObjectInputStreamTest.java
+++ b/src/test/java/org/apache/commons/io/input/ClassLoaderObjectInputStreamTest.java
@@ -94,7 +94,7 @@ public class ClassLoaderObjectInputStreamTest {
         }
     }
 
-    private static enum E {A, B, C}
+    private enum E {A, B, C}
 
     private static class Test implements Serializable {
         private static final long serialVersionUID = 1L;


[commons-io] 06/06: Checkstyle 2.17 -> 3.0.0.

Posted by gg...@apache.org.
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

commit 5ba8b480d647fb3666c7bc775a3fd7b2c6e99aec
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Aug 9 17:14:01 2019 -0400

    Checkstyle 2.17 -> 3.0.0.
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index b278282..7c4fe04 100644
--- a/pom.xml
+++ b/pom.xml
@@ -280,7 +280,7 @@ file comparators, endian transformation classes, and much more.
     </commons.osgi.export>
     <commons.scmPubUrl>https://svn.apache.org/repos/infra/websites/production/commons/content/proper/commons-io/</commons.scmPubUrl>
     <commons.scmPubCheckoutDirectory>site-content</commons.scmPubCheckoutDirectory>
-    <checkstyle.plugin.version>2.17</checkstyle.plugin.version>
+    <checkstyle.plugin.version>3.0.0</checkstyle.plugin.version>
     <commons.jacoco.version>0.8.4</commons.jacoco.version>
     <commons.surefire.version>2.22.2</commons.surefire.version>
     <commons.japicmp.version>0.14.1</commons.japicmp.version>


[commons-io] 03/06: Remove redundant semicolons

Posted by gg...@apache.org.
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

commit fa8525f78a4a89be7c4dad0aa5198c5bfc24262b
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Aug 9 14:09:30 2019 -0400

    Remove redundant semicolons
---
 src/test/java/org/apache/commons/io/input/XmlStreamReaderTest.java    | 4 ++--
 .../commons/io/serialization/ValidatingObjectInputStreamTest.java     | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/test/java/org/apache/commons/io/input/XmlStreamReaderTest.java b/src/test/java/org/apache/commons/io/input/XmlStreamReaderTest.java
index cdb8020..38d2968 100644
--- a/src/test/java/org/apache/commons/io/input/XmlStreamReaderTest.java
+++ b/src/test/java/org/apache/commons/io/input/XmlStreamReaderTest.java
@@ -76,7 +76,7 @@ public class XmlStreamReaderTest {
     protected void _testRawNoBomInvalid(final String encoding) throws Exception {
         final InputStream is = getXmlStream("no-bom", XML3, encoding, encoding);
         try {
-            (new XmlStreamReader(is, false)).close();;
+            (new XmlStreamReader(is, false)).close();
             fail("It should have failed");
         } catch (final IOException ex) {
             assertTrue(ex.getMessage().contains("Invalid encoding,"));
@@ -360,7 +360,7 @@ public class XmlStreamReaderTest {
         final InputStream is = getXmlStream(bomEnc,
                 prologEnc == null ? XML2 : XML3, streamEnc, prologEnc);
         try {
-            (new XmlStreamReader(is, cT, false)).close();;
+            (new XmlStreamReader(is, cT, false)).close();
             fail("It should have failed for HTTP Content-type " + cT + ", BOM "
                     + bomEnc + ", streamEnc " + streamEnc + " and prologEnc "
                     + prologEnc);
diff --git a/src/test/java/org/apache/commons/io/serialization/ValidatingObjectInputStreamTest.java b/src/test/java/org/apache/commons/io/serialization/ValidatingObjectInputStreamTest.java
index 5bfd3ad..3d68557 100644
--- a/src/test/java/org/apache/commons/io/serialization/ValidatingObjectInputStreamTest.java
+++ b/src/test/java/org/apache/commons/io/serialization/ValidatingObjectInputStreamTest.java
@@ -215,7 +215,7 @@ public class ValidatingObjectInputStreamTest extends ClosingBase {
             protected void invalidClassNameFound(final String className) throws InvalidClassException {
                 throw new RuntimeException("Custom exception");
             }
-        };
+        }
 
         assertSerialization(
                 willClose(new CustomVOIS(testStream))


[commons-io] 05/06: Javadoc.

Posted by gg...@apache.org.
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

commit d4f1fdd64ba8d7f744388f7fa8fc46c9deaa7bcb
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Aug 9 14:17:45 2019 -0400

    Javadoc.
---
 src/main/java/org/apache/commons/io/IOIndexedException.java | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/src/main/java/org/apache/commons/io/IOIndexedException.java b/src/main/java/org/apache/commons/io/IOIndexedException.java
index 635c9ad..7b7e1c1 100644
--- a/src/main/java/org/apache/commons/io/IOIndexedException.java
+++ b/src/main/java/org/apache/commons/io/IOIndexedException.java
@@ -40,6 +40,13 @@ public class IOIndexedException extends IOException {
         this.index = index;
     }
 
+    /**
+     * Converts input to a suitable Stirng for exception message.
+     * 
+     * @param index An index into a source collection.
+     * @param cause A cause.
+     * @return A message.
+     */
     protected static String toMessage(final int index, final Throwable cause) {
         // Letting index be any int
         final String unspecified = "Null";