Skip to content

Commit 0e78c7b

Browse files
committed
More indenting fixes
1 parent 1319ad6 commit 0e78c7b

File tree

2 files changed

+95
-7
lines changed

2 files changed

+95
-7
lines changed

xml/System.IO.Compression/ZipArchive.xml

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,33 @@ If the comment byte length is larger than <xref:System.UInt16.MaxValue>, it will
388388
<param name="mode">See the description of the ZipArchiveMode enum. Read requires the stream to support reading, Create requires the stream to support writing, and Update requires the stream to support reading, writing, and seeking.</param>
389389
<param name="leaveOpen">
390390
<see langword="true" /> to leave the stream open upon disposing the ZipArchive, otherwise <see langword="false" />.</param>
391-
<param name="entryNameEncoding"><para>The encoding to use when reading or writing entry names and comments in this ZipArchive.</para><para>NOTE: Specifying this parameter to values other than <see langword="null" /> is discouraged.</para><para>However, this may be necessary for interoperability with ZIP archive tools and libraries that do not correctly support UTF-8 encoding for entry names.&lt;br /&gt; This value is used as follows:</para><para> <strong>Reading (opening) ZIP archive files:</strong></para><para>If <c>entryNameEncoding</c> is not specified (<c>== null</c>):</para><list> <item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header is <em>not</em> set, use the current system default code page (<c>Encoding.Default</c>) in order to decode the entry name and comment.</item> <item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header <em>is</em> set, use UTF-8 (<c>Encoding.UTF8</c>) in order to decode the entry name and comment.</item> </list><para>If <c>entryNameEncoding</c> is specified (<c>!= null</c>):</para><list> <item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header is <em>not</em> set, use the specified <c>entryNameEncoding</c> in order to decode the entry name and comment.</item> <item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header <em>is</em> set, use UTF-8 (<c>Encoding.UTF8</c>) in order to decode the entry name and comment.</item> </list><para> <strong>Writing (saving) ZIP archive files:</strong> </para><para>If <c>entryNameEncoding</c> is not specified (<c>== null</c>):</para><list> <item>For entry names and comments that contain characters outside the ASCII range, the language encoding flag (EFS) will be set in the general purpose bit flag of the local file header, and UTF-8 (<c>Encoding.UTF8</c>) will be used in order to encode the entry name and comment into bytes.</item> <item>For entry names and comments that do not contain characters outside the ASCII range, the language encoding flag (EFS) will not be set in the general purpose bit flag of the local file header, and the current system default code page (<c>Encoding.Default</c>) will be used to encode the entry names and comments into bytes.</item> </list><para>If <c>entryNameEncoding</c> is specified (<c>!= null</c>):</para><list> <item>The specified <c>entryNameEncoding</c> will always be used to encode the entry names and comments into bytes.</para><para>The language encoding flag (EFS) in the general purpose bit flag of the local file header will be set if and only if the specified <c>entryNameEncoding</c> is a UTF-8 encoding.</item> </list><para>Note that Unicode encodings other than UTF-8 may not be currently used for the <c>entryNameEncoding</c>, otherwise an <see cref="T:System.ArgumentException" /> is thrown.</para></param>
391+
<param name="entryNameEncoding">
392+
<para>The encoding to use when reading or writing entry names and comments in this ZipArchive.</para>
393+
<para>NOTE: Specifying this parameter to values other than <see langword="null" /> is discouraged.</para>
394+
<para>However, this may be necessary for interoperability with ZIP archive tools and libraries that do not correctly support UTF-8 encoding for entry names.&lt;br /&gt; This value is used as follows:</para>
395+
<para><strong>Reading (opening) ZIP archive files:</strong></para>
396+
<para>If <c>entryNameEncoding</c> is not specified (<c>== null</c>):</para>
397+
<list>
398+
<item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header is <em>not</em> set, use the current system default code page (<c>Encoding.Default</c>) in order to decode the entry name and comment.</item>
399+
<item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header <em>is</em> set, use UTF-8 (<c>Encoding.UTF8</c>) in order to decode the entry name and comment.</item>
400+
</list>
401+
<para>If <c>entryNameEncoding</c> is specified (<c>!= null</c>):</para>
402+
<list>
403+
<item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header is <em>not</em> set, use the specified <c>entryNameEncoding</c> in order to decode the entry name and comment.</item>
404+
<item>For entries where the language encoding flag (EFS) in the general purpose bit flag of the local file header <em>is</em> set, use UTF-8 (<c>Encoding.UTF8</c>) in order to decode the entry name and comment.</item>
405+
</list>
406+
<para><strong>Writing (saving) ZIP archive files:</strong> </para>
407+
<para>If <c>entryNameEncoding</c> is not specified (<c>== null</c>):</para>
408+
<list>
409+
<item>For entry names and comments that contain characters outside the ASCII range, the language encoding flag (EFS) will be set in the general purpose bit flag of the local file header, and UTF-8 (<c>Encoding.UTF8</c>) will be used in order to encode the entry name and comment into bytes.</item>
410+
<item>For entry names and comments that do not contain characters outside the ASCII range, the language encoding flag (EFS) will not be set in the general purpose bit flag of the local file header, and the current system default code page (<c>Encoding.Default</c>) will be used to encode the entry names and comments into bytes.</item>
411+
</list>
412+
<para>If <c>entryNameEncoding</c> is specified (<c>!= null</c>):</para>
413+
<list>
414+
<item>The specified <c>entryNameEncoding</c> will always be used to encode the entry names and comments into bytes.</item>
415+
</list>
416+
<para>The language encoding flag (EFS) in the general purpose bit flag of the local file header will be set if and only if the specified <c>entryNameEncoding</c> is a UTF-8 encoding.</para>
417+
</param>
392418
<param name="cancellationToken">The optional cancellation token to monitor.</param>
393419
<summary>Asynchronously initializes and returns a new instance of <see cref="T:System.IO.Compression.ZipArchive" /> on the given stream in the specified mode, specifying whether to leave the stream open, with an optional encoding and an optional cancellation token.</summary>
394420
<returns>To be added.</returns>

0 commit comments

Comments
 (0)