Skip to content

Commit 6f795ec

Browse files
carlossanlopRon Petrusha
authored andcommitted
Automatically port System.Text.Json.JsonEncodedText (dotnet#3012)
* Automatically port System.Text.Json.JsonEncodedText * Some edits.
1 parent 776fbb4 commit 6f795ec

File tree

1 file changed

+28
-12
lines changed

1 file changed

+28
-12
lines changed

xml/System.Text.Json/JsonEncodedText.xml

Lines changed: 28 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,16 @@ This type can be used to cache and store known strings used for writing JSON ahe
5454
<Parameter Name="encoder" Type="System.Text.Encodings.Web.JavaScriptEncoder" />
5555
</Parameters>
5656
<Docs>
57-
<param name="utf8Value">To be added.</param>
58-
<param name="encoder">To be added.</param>
59-
<summary>To be added.</summary>
60-
<returns>To be added.</returns>
57+
<param name="utf8Value">The UTF-8 encoded text to convert to JSON encoded text.</param>
58+
<param name="encoder">The encoder to use when escaping the string, or <see langword="null" /> to use the default encoder.</param>
59+
<summary>Encodes a UTF-8 text value as a JSON string.</summary>
60+
<returns>The encoded JSON text.</returns>
6161
<remarks>To be added.</remarks>
62+
<exception cref="T:System.ArgumentException"><paramref name="utf8Value" /> is too large.
63+
64+
-or-
65+
66+
<paramref name="utf8Value" /> contains invalid UTF-8 bytes.</exception>
6267
</Docs>
6368
</Member>
6469
<Member MemberName="Encode">
@@ -80,11 +85,16 @@ This type can be used to cache and store known strings used for writing JSON ahe
8085
<Parameter Name="encoder" Type="System.Text.Encodings.Web.JavaScriptEncoder" />
8186
</Parameters>
8287
<Docs>
83-
<param name="value">To be added.</param>
84-
<param name="encoder">To be added.</param>
85-
<summary>To be added.</summary>
86-
<returns>To be added.</returns>
88+
<param name="value">The value to convert to JSON encoded text.</param>
89+
<param name="encoder">The encoder to use when escaping the string, or <see langword="null" /> to use the default encoder.</param>
90+
<summary>Encodes a specified text value as a JSON string.</summary>
91+
<returns>The encoded JSON text.</returns>
8792
<remarks>To be added.</remarks>
93+
<exception cref="T:System.ArgumentException"><paramref name="value" /> is too large.
94+
95+
-or-
96+
97+
<paramref name="value" /> contains invalid UTF-16 characters.</exception>
8898
</Docs>
8999
</Member>
90100
<Member MemberName="Encode">
@@ -106,11 +116,17 @@ This type can be used to cache and store known strings used for writing JSON ahe
106116
<Parameter Name="encoder" Type="System.Text.Encodings.Web.JavaScriptEncoder" />
107117
</Parameters>
108118
<Docs>
109-
<param name="value">To be added.</param>
110-
<param name="encoder">To be added.</param>
111-
<summary>To be added.</summary>
112-
<returns>To be added.</returns>
119+
<param name="value">The value to convert to JSON encoded text.</param>
120+
<param name="encoder">The encoder to use when escaping the string, or <see langword="null" /> to use the default encoder.</param>
121+
<summary>Encodes the string text value as a JSON string.</summary>
122+
<returns>The encoded JSON text.</returns>
113123
<remarks>To be added.</remarks>
124+
<exception cref="T:System.ArgumentNullException"><paramref name="value" /> is <see langword="null" />.</exception>
125+
<exception cref="T:System.ArgumentException"><paramref name="value" /> is too large.
126+
127+
-or-
128+
129+
<paramref name="value" /> contains invalid UTF-16 characters.</exception>
114130
</Docs>
115131
</Member>
116132
<Member MemberName="EncodedUtf8Bytes">

0 commit comments

Comments
 (0)