JDK 9 doc-only RFR of 8180353: FileOutputStream documentation does not indicate properly whether files get truncated or not

Brian Burkhalter brian.burkhalter at oracle.com
Tue May 16 01:27:59 UTC 2017

Please review at your convenience.

Issue:	https://bugs.openjdk.java.net/browse/JDK-8180353
Patch:	[1]



[1] Hg diff

--- a/src/java.base/share/classes/java/io/FileOutputStream.java
+++ b/src/java.base/share/classes/java/io/FileOutputStream.java
@@ -91,6 +91,12 @@
      * If the file exists but is a directory rather than a regular file, does
      * not exist but cannot be created, or cannot be opened for any other
      * reason then a <code>FileNotFoundException</code> is thrown.
+     * <p>
+     * Invoking this constructor with the parameter {@code name} is equivalent
+     * to invoking the constructor {@link #FileOutputStream(String,boolean)
+     * FileOutputStream(name,append)} with the same {@code String} parameter
+     * {@code name} and the {@code boolean} parameter {@code append} equal to
+     * {@code false}.
      * @param      name   the system-dependent filename
      * @exception  FileNotFoundException  if the file exists but is a directory

More information about the core-libs-dev mailing list