|
1 | 1 |
|
| 2 | +Apache Commons IO 2.16.0 Release Notes |
| 3 | + |
| 4 | +Introduction |
| 5 | +------------ |
| 6 | + |
| 7 | +Commons IO is a package of Java utility classes like java.io. |
| 8 | +Classes in this package are considered to be so standard and of such high |
| 9 | +reuse as to justify existence in java.io. |
| 10 | + |
| 11 | +The Apache Commons IO library contains utility classes, stream implementations, file filters, |
| 12 | +file comparators, endian transformation classes, and much more. |
| 13 | + |
| 14 | +Java 8 is required. |
| 15 | + |
| 16 | +New features |
| 17 | +------------ |
| 18 | + |
| 19 | +o Add and use PathUtils.getFileName(Path, Function<Path, R>). Thanks to Gary Gregory. |
| 20 | +o Add and use PathUtils.getFileNameString(). Thanks to Gary Gregory. |
| 21 | +o Make public Erase.rethrow(Throwable). Thanks to Gary Gregory. |
| 22 | +o IO-826: Add BrokenInputStream.BrokenInputStream(Throwable). Thanks to markslater, Gary Gregory. |
| 23 | +o IO-826: Add BrokenReader.BrokenReader(Throwable). Thanks to markslater, Gary Gregory. |
| 24 | +o IO-826: Add BrokenOutputStream.BrokenOutputStream(Throwable). Thanks to markslater, Gary Gregory. |
| 25 | +o IO-826: Add BrokenWriter.BrokenWriter(Throwable). Thanks to markslater, Gary Gregory. |
| 26 | +o Add BoundedInputStream.getRemaining(). Thanks to Gary Gregory. |
| 27 | +o Add FileTimes.toNtfsTime(long). Thanks to Gary Gregory. |
| 28 | +o Add FileTimes.fromUnixTime(long). Thanks to Gary Gregory. |
| 29 | +o Add FileTimes.isUnixTime(FileTime). Thanks to Gary Gregory. |
| 30 | +o Add FileTimes.isUnixTime(long). Thanks to Gary Gregory. |
| 31 | +o Add FileTimes.toUnixTime(FileTime). Thanks to Gary Gregory. |
| 32 | +o Add BrokenInputStream.Builder. Thanks to Gary Gregory. |
| 33 | +o Add PathUtils.getExtension(Path). Thanks to Gary Gregory. |
| 34 | +o Add PathUtils.getBaseName(Path). Thanks to Gary Gregory. |
| 35 | +o Add ThrottledInputStream. Thanks to Gary Gregory. |
| 36 | +o Add IORunnable.noop(). Thanks to Gary Gregory. |
| 37 | +o Add ChecksumInputStream and test #548. Thanks to Gary Gregory. |
| 38 | +o Add AbstractStreamBuilder.getReader(). Thanks to Gary Gregory. |
| 39 | +o Add Maven property project.build.outputTimestamp for build reproducibility. Thanks to Gary Gregory. |
| 40 | +o Add ProxyInputStream.unwrap(). Thanks to Gary Gregory. |
| 41 | +o Add a running count and builder to BoundedInputStream. Thanks to Gary Gregory. |
| 42 | + |
| 43 | +Fixed Bugs |
| 44 | +---------- |
| 45 | + |
| 46 | +o Fix and re-enable testSkip_RequiredCharsets #518. Thanks to Elliotte Rusty Harold. |
| 47 | +o IO-824: SymbolicLineFileFilter documentation fixes. Thanks to Miguel Munoz, Gary Gregory. |
| 48 | +o IO-795: CharSequenceInputStream.reset() only works once #520. Thanks to Miguel Munoz, Gary Gregory. |
| 49 | +o IO-795: Finish TODO on CharSequenceInputStream #540. Thanks to Elliotte Rusty Harold. |
| 50 | +o IO-825: Add byte array size validation for methods in EndianUtils #521. Thanks to Arthur Chan, Gary Gregory. |
| 51 | +o IO-825: Add missing test case CircularByteBufferTest. Thanks to dkdal, Gary Gregory. |
| 52 | +o IO-781: Make CharSequenceInputStream.available() more correct in the face of multibyte encodings #525. Thanks to Elliotte Rusty Harold. |
| 53 | +o IO-781: Remove unreachable code in AbstractIOFileFilterTest #526. Thanks to Elliotte Rusty Harold. |
| 54 | +o IO-808: Rationalize and unify checking for existence of files and directories #529. Thanks to Elliotte Rusty Harold. |
| 55 | +o Avoid NullPointerException in IOCase.checkEquals(String, String) on null input. Thanks to Gary Gregory. |
| 56 | +o Avoid NullPointerException in CanExecuteFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 57 | +o Avoid NullPointerException in CanExecuteFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 58 | +o Avoid NullPointerException in CanReadFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 59 | +o Avoid NullPointerException in CanReadFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 60 | +o Avoid NullPointerException in CanWriteFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 61 | +o Avoid NullPointerException in CanWriteFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 62 | +o Avoid NullPointerException in DirectoryFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 63 | +o Avoid NullPointerException in DirectoryFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 64 | +o Avoid NullPointerException in EmptyFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 65 | +o Avoid NullPointerException in EmptyFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 66 | +o Avoid NullPointerException in FileFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 67 | +o Avoid NullPointerException in FileFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 68 | +o Avoid NullPointerException in HiddenFileFilter.accept(File) on null input. Thanks to Gary Gregory. |
| 69 | +o Avoid NullPointerException in HiddenFileFilter.accept(Path, BasicFileAttributes) on null input. Thanks to Gary Gregory. |
| 70 | +o Avoid NullPointerException in IOCase.checkIndexOf(String, int, String) on null input. Thanks to Gary Gregory. |
| 71 | +o Avoid NullPointerException in IOCase.checkRegionMatches(String, int, String) on null input. Thanks to Gary Gregory. |
| 72 | +o BoundedInputStream.getCount() should not count EOF. Thanks to Gary Gregory. |
| 73 | +o Modernize temporary file creation and deletion in DeferredFileOutputStreamTest #535. Thanks to Elliotte Rusty Harold, Gary Gregory. |
| 74 | +o Add PathMatcher to IOFileFilter class Javadoc #536. Thanks to Elliotte Rusty Harold. |
| 75 | +o IO-781: Fix CharSequenceInputStream coding exception handling #537. Thanks to Marcono1234. |
| 76 | +o IO-781: Deprecate int CountingInputStream#getCount() in favor of long CountingInputStream#getByteCount(). Thanks to Marcono1234. |
| 77 | +o IO-828: Deprecate CountingInputStream.resetCount() in favor of resetByteCount(). Thanks to Elliotte Rusty Harold, Gary Gregory. |
| 78 | +o IO-828: Deprecate CountingInputStream.getMaxLength() in favor of getMaxCount()). Thanks to Gary Gregory. |
| 79 | +o IO-818: NullInputStream breaks InputStream's read method contract. Thanks to Gary Gregory. |
| 80 | +o Javadoc shouldn't reference 1.x behavior #539. Thanks to Elliotte Rusty Harold. |
| 81 | +o IO-829: Don't decode and reencode characters in a potentially different charset in AbstractOrigin.CharSequenceOrigin.getReader(Charset). Thanks to Elliotte Rusty Harold, Gary Gregory. |
| 82 | +o Let subclasses of CountingInputStream.afterRead(int) throw IOException. Thanks to Gary Gregory. |
| 83 | +o IO-807: Characterization test for broken symlinks when copying directories #547. Thanks to Elliotte Rusty Harold, Gary Gregory. |
| 84 | +o ClosedInputStream.read(byte[], int, int) does not always return -1. Thanks to Gary Gregory. |
| 85 | +o ClosedOutputStream.write(byte[], int, int) does not always throw IOException. Thanks to Gary Gregory. |
| 86 | +o XmlStreamReader can't parse an XML document with a multi-line prolog #550. Thanks to Sylwester Lachiewicz, Gary Gregory. |
| 87 | +o XmlStreamReader can't parse XML an document with an external parsed entity prolog. Thanks to Andreas Hubold, Gary Gregory. |
| 88 | +o IO-836: Update FileNameUtils Javadoc #554. Thanks to Elliotte Rusty Harold. |
| 89 | +o IO-807: Copy symlinks, not the files the symlinks point to #558. Thanks to Jordi Sola, Elliotte Rusty Harold. |
| 90 | +o Pickup apache-rat-plugin version from parent POM. Thanks to Gary Gregory. |
| 91 | +o Add test for copying a symlink FileUtilsTest#testCopyFile_symLink() #564. Thanks to Elliotte Rusty Harold. |
| 92 | +o Make copyFile copy symbolic links by value rather than reference #565. Thanks to Elliotte Rusty Harold. |
| 93 | +o Deprecate CopyUtils 0-argument constructor. Thanks to Gary Gregory. |
| 94 | +o IO-843: Deprecate EndianUtils 0-argument constructor. Thanks to Gary Gregory, Elliotte Rusty Harold. |
| 95 | +o Deprecate FileSystemUtils 0-argument constructor. Thanks to Gary Gregory. |
| 96 | +o Deprecate FilenameUtils 0-argument constructor. Thanks to Gary Gregory. |
| 97 | +o Deprecate RandomAccessFiles 0-argument constructor. Thanks to Gary Gregory. |
| 98 | +o Clarify and correct EndianUtils and SwappedDataInputStream API doc #566. Thanks to Elliotte Rusty Harold, Gary Gregory. |
| 99 | +o Add characterization test for copying a symlinked directory #570. Thanks to Elliotte Rusty Harold. |
| 100 | +o RandomAccessFileInputStream.builder().get() now throws ISE instead of NPE. Thanks to Gary Gregory. |
| 101 | +o IO-845: Test links to targets outside the source directory #571. Thanks to Elliotte Rusty Harold. |
| 102 | +o Focus Javadoc on current version rather than past versions #573, #574. Thanks to Elliotte Rusty Harold. |
| 103 | +o IO-469: "Self-suppression not permitted" while using BrokenOutput and BrokenInput streams with try-with-resources. Thanks to Grigory Fadeev, Kristian Rosenvold, Elliotte Rusty Harold. |
| 104 | +o IO-405: Handle zero and negative thresholds #587. Thanks to Elliotte Rusty Harold. |
| 105 | +o Deprecate CountingInputStream in favor of BoundedInputStream. Thanks to Gary Gregory. |
| 106 | +o PathUtils.setPosixPermissions(...) only sets permissions if needed. Thanks to Gary Gregory. |
| 107 | +o PathUtils.setReadOnly(...) only sets permissions if needed. Thanks to Gary Gregory. |
| 108 | +o PathUtils.deleteFile(..., DeleteOption...) only sets permissions if needed. Thanks to Gary Gregory. |
| 109 | +o CleaningPathVisitor only sets permissions if needed. Thanks to Gary Gregory. |
| 110 | +o DeletingPathVisitor only sets permissions if needed. Thanks to Gary Gregory. |
| 111 | + |
| 112 | +Changes |
| 113 | +------- |
| 114 | + |
| 115 | +o Bump commons.bytebuddy.version from 1.14.10 to 1.14.12 #534, #592. Thanks to Gary Gregory. |
| 116 | +o Bump org.apache.commons:commons-parent from 65 to 67. Thanks to Gary Gregory. |
| 117 | +o Bump commons-codec:commons-codec from 1.16.0 to 1.16.1 #583. Thanks to Dependabot. |
| 118 | +o Bump org.codehaus.mojo:exec-maven-plugin from 3.1.1 to 3.2.0 #593. Thanks to Dependabot. |
| 119 | + |
| 120 | + |
| 121 | +Commons IO 2.7 and up requires Java 8 or above. |
| 122 | +Commons IO 2.6 requires Java 7 or above. |
| 123 | +Commons IO 2.3 through 2.5 requires Java 6 or above. |
| 124 | +Commons IO 2.2 requires Java 5 or above. |
| 125 | +Commons IO 1.4 requires Java 1.3 or above. |
| 126 | + |
| 127 | +Historical list of changes: https://commons.apache.org/proper/commons-io/changes-report.html |
| 128 | + |
| 129 | +For complete information on Apache Commons IO, including instructions on how to submit bug reports, |
| 130 | +patches, or suggestions for improvement, see the Apache Commons IO website: |
| 131 | + |
| 132 | +https://commons.apache.org/proper/commons-io/ |
| 133 | + |
| 134 | +Download page: https://commons.apache.org/proper/commons-io/download_io.cgi |
| 135 | + |
| 136 | +Have fun! |
| 137 | +-Apache Commons Team |
| 138 | + |
| 139 | +------------------------------------------------------------------------------ |
| 140 | + |
| 141 | + |
2 | 142 | Apache Commons IO
|
3 | 143 | Version 2.15.1
|
4 | 144 | Release Notes
|
|
0 commit comments