8000 NET Interactive: Enable_try_dotnet_to_batch_12d (#4425) · dotnet/dotnet-api-docs@24edf30 · GitHub
[go: up one dir, main page]

Skip to content

Commit 24edf30

Browse files
v-mepamairaw
andauthored
NET Interactive: Enable_try_dotnet_to_batch_12d (#4425)
* enable_try_dotnet_to_batch_12d * Update xml/System/Exception.xml Removing interactive Co-authored-by: Maira Wenzel <mairaw@microsoft.com> Co-authored-by: Maira Wenzel <mairaw@microsoft.com>
1 parent 92a81e3 commit 24edf30

File tree

2 files changed

+44
-48
lines changed

2 files changed

+44
-48
lines changed

xml/System/Byte.xml

Lines changed: 41 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,18 @@
347347
</AssemblyInfo>
348348
<Docs>
349349
<summary>Returns a value indicating whether two instances of <see cref="T:System.Byte" /> represent the same value.</summary>
350+
<remarks>
351+
<format type="text/markdown"><![CDATA[
352+
353+
## Examples
354+
The following code example determines whether the first <xref:System.Byte> value is equal to the second <xref:System.Byte> value, and whether the first <xref:System.Byte> value is equal to the boxed version of the second <xref:System.Byte> value.
355+
356+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.byte.equals/cpp/eq.cpp" id="Snippet1":::
357+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.byte.equals/cs/eq.cs" interactive="try-dotnet" id="Snippet1":::
358+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.byte.equals/vb/eq.vb" id="Snippet1":::
359+
360+
]]></format>
361+
</remarks>
350362
</Docs>
351363
</MemberGroup>
352364
<Member MemberName="Equals">
@@ -398,16 +410,7 @@
398410
399411
## Remarks
400412
This method implements the <xref:System.IEquatable%601?displayProperty=nameWithType> interface, and performs slightly better than <xref:System.Byte.Equals%28System.Object%29> because it does not have to convert the `obj` parameter to an object.
401-
402-
403-
404-
## Examples
405-
The following code example determines whether the first <xref:System.Byte> value is equal to the second <xref:System.Byte> value, and whether the first <xref:System.Byte> value is equal to the boxed version of the second <xref:System.Byte> value.
406-
407-
[!code-cpp[system.byte.equals#1](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.byte.equals/cpp/eq.cpp#1)]
408-
[!code-csharp[system.byte.equals#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.byte.equals/cs/eq.cs#1)]
409-
[!code-vb[system.byte.equals#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.byte.equals/vb/eq.vb#1)]
410-
413+
411414
]]></format>
412415
</remarks>
413416
<altmember cref="M:System.Byte.Equals(System.Object)" />
@@ -457,14 +460,7 @@
457460
<see langword="true" /> if <paramref name="obj" /> is an instance of <see cref="T:System.Byte" /> and equals the value of this instance; otherwise, <see langword="false" />.</returns>
458461
<remarks>
459462
<format type="text/markdown"><![CDATA[
460-
461-
## Examples
462-
The following code example determines whether the first <xref:System.Byte> value is equal to the second <xref:System.Byte> value, and whether the first <xref:System.Byte> value is equal to the boxed version of the second <xref:System.Byte> value.
463-
464-
[!code-cpp[system.byte.equals#1](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.byte.equals/cpp/eq.cpp#1)]
465-
[!code-csharp[system.byte.equals#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.byte.equals/cs/eq.cs#1)]
466-
[!code-vb[system.byte.equals#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.byte.equals/vb/eq.vb#1)]
467-
463+
468464
]]></format>
469465
</remarks>
470466
<altmember cref="M:System.Byte.CompareTo(System.Object)" />
@@ -746,9 +742,9 @@
746742
## Examples
747743
The following example demonstrates how to convert a string value into a byte value using the <xref:System.Byte.Parse%28System.St 8000 ring%29?displayProperty=nameWithType> method. The resulting byte value is then displayed to the console.
748744
749-
[!code-cpp[System.Byte.Parse#1](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp#1)]
750-
[!code-csharp[System.Byte.Parse#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs#1)]
751-
[!code-vb[System.Byte.Parse#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb#1)]
745+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp" id="Snippet1":::
746+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs" interactive="try-dotnet-method" id="Snippet1":::
747+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb" id="Snippet1":::
752748
753749
]]></format>
754750
</remarks>
@@ -862,9 +858,9 @@
862858
## Examples
863859
The following example parses string representations of `Byte` values with the <xref:System.Byte.Parse%28System.String%2CSystem.Globalization.NumberStyles%29?displayProperty=nameWithType> method. The current culture for the example is en-US.
864860
865-
[!code-cpp[System.Byte.Parse#3](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp#3)]
866-
[!code-csharp[System.Byte.Parse#3](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs#3)]
867-
[!code-vb[System.Byte.Parse#3](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb#3)]
861+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp" id="Snippet3":::
862+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs" interactive="try-dotnet-method" id="Snippet3":::
863+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb" id="Snippet3":::
868864
869865
]]></format>
870866
</remarks>
@@ -962,9 +958,9 @@
962958
## Examples
963959
The following example parses string representations of `Byte` values with the <xref:System.Byte.Parse%2A> method.
964960
965-
[!code-cpp[System.Byte.Parse#2](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp#2)]
966-
[!code-csharp[System.Byte.Parse#2](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs#2)]
967-
[!code-vb[System.Byte.Parse#2](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb#2)]
961+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp" id="Snippet2":::
962+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs" interactive="try-dotnet-method" id="Snippet2":::
963+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb" id="Snippet2":::
968964
969965
]]></format>
970966
</remarks>
@@ -1118,9 +1114,9 @@
11181114
## Examples
11191115
The following code example parses string representations of `Byte` values with this overload of the <xref:System.Byte.Parse%28System.String%2CSystem.Globalization.NumberStyles%2CSystem.IFormatProvider%29?displayProperty=nameWithType> method.
11201116
1121-
[!code-cpp[System.Byte.Parse#4](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp#4)]
1122-
[!code-csharp[System.Byte.Parse#4](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs#4)]
1123-
[!code-vb[System.Byte.Parse#4](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb#4)]
1117+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.Parse/cpp/parse.cpp" id="Snippet4":::
1118+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.Parse/CS/parse.cs" interactive="try-dotnet-method" id="Snippet4":::
1119+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.Parse/VB/parse.vb" id="Snippet4":::
11241120
11251121
]]></format>
11261122
</remarks>
@@ -2117,9 +2113,9 @@ This member is an explicit interface member implementation. It can be used only
21172113
## Examples
21182114
The following example displays an array of byte values. Note that the <xref:System.Byte.ToString> method is not called explicitly in the example. Instead, it is called implicitly, because of the use of the [composite formatting](/dotnet/standard/base-types/composite-formatting) feature.
21192115
2120-
[!code-cpp[System.Byte.ToString#2](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.ToString/CPP/newbytemembers2.cpp#2)]
2121-
[!code-csharp[System.Byte.ToString#2](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.ToString/CS/NewByteMembers.cs#2)]
2122-
[!code-vb[System.Byte.ToString#2](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.ToString/VB/NewByteMembers.vb#2)]
2116+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.ToString/CPP/newbytemembers2.cpp" id="Snippet2":::
2117+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.ToString/CS/NewByteMembers.cs" interactive="try-dotnet-method" id="Snippet2":::
2118+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.ToString/VB/NewByteMembers.vb" id="Snippet2":::
21232119
21242120
]]></format>
21252121
</remarks>
@@ -2203,9 +2199,9 @@ This member is an explicit interface member imp F438 lementation. It can be used only
22032199
## Examples
22042200
The following example iterates an array of byte values and displays each of them to the console by calling the <xref:System.Byte.ToString%28System.IFormatProvider%29> method with different format providers.
22052201
2206-
[!code-cpp[System.Byte.ToString#3](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.ToString/CPP/newbytemembers.cpp#3)]
2207-
[!code-csharp[System.Byte.ToString#3](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.ToString/CS/NewByteMembers.cs#3)]
2208-
[!code-vb[System.Byte.ToString#3](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.ToString/VB/NewByteMembers.vb#3)]
2202+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.ToString/CPP/newbytemembers.cpp" id="Snippet3":::
2203+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.ToString/CS/NewByteMembers.cs" interactive="try-dotnet-method" id="Snippet3":::
2204+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.ToString/VB/NewByteMembers.vb" id="Snippet3":::
22092205
22102206
]]></format>
22112207
</remarks>
@@ -2371,9 +2367,9 @@ This member is an explicit interface member implementation. It can be used only
23712367
## Examples
23722368
The following example uses the standard "N" format string and four different <xref:System.Globalization.CultureInfo> objects to display the string representation of a byte value to the console.
23732369
2374-
[!code-cpp[System.Byte.ToString#5](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.ToString/CPP/newbytemembers2.cpp#5)]
2375-
[!code-csharp[System.Byte.ToString#5](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.ToString/CS/NewByteMembers.cs#5)]
2376-
[!code-vb[System.Byte.ToString#5](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.ToString/VB/NewByteMembers.vb#5)]
2370+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.ToString/CPP/newbytemembers2.cpp" id="Snippet5":::
2371+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.ToString/CS/NewByteMembers.cs" interactive="try-dotnet-method" id="Snippet5":::
2372+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.ToString/VB/NewByteMembers.vb" id="Snippet5":::
23772373
23782374
]]></format>
23792375
</remarks>
@@ -2557,9 +2553,9 @@ This member is an explicit interface member implementation. It can be used only
25572553
## Examples
25582554
The following example calls the <xref:System.Byte.TryParse%28System.String%2CSystem.Byte%40%29> method with a number of different string values.
25592555
2560-
[!code-cpp[System.Byte.TryParse#1](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.TryParse/cpp/tryparse.cpp#1)]
2561-
[!code-csharp[System.Byte.TryParse#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.TryParse/cs/TryParse.cs#1)]
2562-
[!code-vb[System.Byte.TryParse#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.TryParse/vb/TryParse.vb#1)]
2556+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.TryParse/cpp/tryparse.cpp" id="Snippet1":::
2557+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.TryParse/cs/TryParse.cs" interactive="try-dotnet" id="Snippet1":::
2558+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.TryParse/vb/TryParse.vb" id="Snippet1":::
25632559
25642560
]]></format>
25652561
</remarks>
@@ -2711,9 +2707,9 @@ This member is an explicit interface member implementation. It can be used only
27112707
## Examples
27122708
The following example calls the <xref:System.Byte.TryParse%28System.String%2CSystem.Globalization.NumberStyles%2CSystem.IFormatProvider%2CSystem.Byte%40%29> method with a number of different string values.
27132709
2714-
[!code-cpp[System.Byte.TryParse#2](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.TryParse/cpp/tryparse2.cpp#2)]
2715-
[!code-csharp[System.Byte.TryParse#2](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.TryParse/cs/TryParse2.cs#2)]
2716-
[!code-vb[System.Byte.TryParse#2](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.TryParse/vb/TryParse2.vb#2)]
2710+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.Byte.TryParse/cpp/tryparse2.cpp" id="Snippet2":::
2711+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.Byte.TryParse/cs/TryParse2.cs" interactive="try-dotnet" id="Snippet2":::
2712+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.Byte.TryParse/vb/TryParse2.vb" id="Snippet2":::
27172713
27182714
]]></format>
27192715
</remarks>

xml/System/Exception.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1435,9 +1435,9 @@ Stack Trace:
14351435
## Examples
14361436
The following example causes an exception and displays the result of calling <xref:System.Exception.ToString%2A> on that exception. Note that the <xref:System.Exception.ToString%2A?displayProperty=nameWithType> method is called implicitly when the Exception class instance appears in the argument list of the <xref:System.Console.WriteLine%2A?displayProperty=nameWithType> method.
14371437
1438-
[!code-cpp[System.Exception.ToString#1](~/samples/snippets/cpp/VS_Snippets_CLR_System/system.exception.tostring/cpp/ToStringEx1.cpp#1)]
1439-
[!code-csharp[System.Exception.ToString#1](~/samples/snippets/csharp/VS_Snippets_CLR_System/system.exception.tostring/cs/ToStringEx1.cs#1)]
1440-
[!code-vb[System.Exception.ToString#1](~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.exception.tostring/vb/ToStringEx1.vb#1)]
1438+
:::code language="cpp" source="~/samples/snippets/cpp/VS_Snippets_CLR_System/system.exception.tostring/cpp/ToStringEx1.cpp" id="Snippet1":::
1439+
:::code language="csharp" source="~/samples/snippets/csharp/VS_Snippets_CLR_System/system.exception.tostring/cs/ToStringEx1.cs" id="Snippet1":::
1440+
:::code language="vb" source="~/samples/snippets/visualbasic/VS_Snippets_CLR_System/system.exception.tostring/vb/ToStringEx1.vb" id="Snippet1":::
14411441
14421442
]]></format>
14431443
</remarks>

0 commit comments

Comments
 (0)
0