src/share/classes/java/util/zip/ZipFile.java

Print this page
rev 3975 : 4884238: Adds java.nio.charset.StandardCharset to provide static final constants for the standard charsets.

*** 29,38 **** --- 29,39 ---- import java.io.InputStream; import java.io.IOException; import java.io.EOFException; import java.io.File; import java.nio.charset.Charset; + import java.nio.charset.StandardCharset; import java.util.ArrayDeque; import java.util.Deque; import java.util.Enumeration; import java.util.HashMap; import java.util.Map;
*** 138,148 **** * @throws IllegalArgumentException if the <tt>mode</tt> argument is invalid * @see SecurityManager#checkRead(java.lang.String) * @since 1.3 */ public ZipFile(File file, int mode) throws IOException { ! this(file, mode, Charset.forName("UTF-8")); } /** * Opens a ZIP file for reading given the specified File object. * --- 139,149 ---- * @throws IllegalArgumentException if the <tt>mode</tt> argument is invalid * @see SecurityManager#checkRead(java.lang.String) * @since 1.3 */ public ZipFile(File file, int mode) throws IOException { ! this(file, mode, StandardCharset.UTF_8); } /** * Opens a ZIP file for reading given the specified File object. *