Skip to content

Commit 1497e34

Browse files
Merge pull request dotnet#10361 from tannergooding/system-runtime
Updating the documentation for System.Runtime
2 parents c98899a + cfc4d2e commit 1497e34

File tree

6 files changed

+109
-78
lines changed

6 files changed

+109
-78
lines changed

xml/System/Environment+ProcessCpuUsage.xml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,10 @@
2828
</Attribute>
2929
</Attributes>
3030
<Docs>
31-
<summary>To be added.</summary>
32-
<remarks>To be added.</remarks>
31+
<summary>Represents the CPU usage statistics of a process.</summary>
32+
<remarks>
33+
<para>The CPU usage statistics include information about the time spent by the process in the application code (user mode) and the operating system code (kernel mode), as well as the total time spent by the process in both user mode and kernel mode.</para>
34+
</remarks>
3335
</Docs>
3436
<Members>
3537
<Member MemberName="PrivilegedTime">
@@ -48,7 +50,7 @@
4850
<ReturnType>System.TimeSpan</ReturnType>
4951
</ReturnValue>
5052
<Docs>
51-
<summary>To be added.</summary>
53+
<summary>Gets the amount of time the process has spent running code inside the operating system code.</summary>
5254
<value>To be added.</value>
5355
<remarks>To be added.</remarks>
5456
</Docs>
@@ -69,7 +71,7 @@
6971
<ReturnType>System.TimeSpan</ReturnType>
7072
</ReturnValue>
7173
<Docs>
72-
<summary>To be added.</summary>
74+
<summary>Gets the amount of time the process has spent utilizing the CPU, including the process time spent in the application code and in the operating system code.</summary>
7375
<value>To be added.</value>
7476
<remarks>To be added.</remarks>
7577
</Docs>
@@ -90,7 +92,7 @@
9092
<ReturnType>System.TimeSpan</ReturnType>
9193
</ReturnValue>
9294
<Docs>
93-
<summary>To be added.</summary>
95+
<summary>Gets the amount of time the associated process has spent running code inside the application portion of the process (not the operating system code).</summary>
9496
<value>To be added.</value>
9597
<remarks>To be added.</remarks>
9698
</Docs>

xml/System/Environment.xml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,9 @@
202202
<ReturnType>System.Environment+ProcessCpuUsage</ReturnType>
203203
</ReturnValue>
204204
<Docs>
205-
<summary>To be added.</summary>
205+
<summary>
206+
<para>Get the CPU usage, including the process time spent running the application code, the process time spent running the operating system code, and the total time spent running both the application and operating system code.</para>
207+
</summary>
206208
<value>To be added.</value>
207209
<remarks>To be added.</remarks>
208210
</Docs>

xml/System/Guid.xml

Lines changed: 26 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -603,8 +603,8 @@
603603
<ReturnType>System.Guid</ReturnType>
604604
</ReturnValue>
605605
<Docs>
606-
<summary>To be added.</summary>
607-
<value>To be added.</value>
606+
<summary>Gets a <see cref="T:System.Guid" /> where all bits are set.</summary>
607+
<value>A GUID with a value of FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFFF.</value>
608608
<remarks>To be added.</remarks>
609609
</Docs>
610610
</Member>
@@ -846,9 +846,12 @@
846846
</ReturnValue>
847847
<Parameters />
848848
<Docs>
849-
<summary>To be added.</summary>
850-
<returns>To be added.</returns>
851-
<remarks>To be added.</remarks>
849+
<summary>Creates a new <see cref="T:System.Guid" /> according to RFC 9562, following the Version 7 format.</summary>
850+
<returns>A new <see cref="T:System.Guid" /> according to RFC 9562, following the Version 7 format.</returns>
851+
<remarks>
852+
<para>This method uses <see cref="P:System.DateTimeOffset.UtcNow" /> to determine the Unix Epoch timestamp source.</para>
853+
<para>This method seeds the rand_a and rand_b sub-fields with random data.</para>
854+
</remarks>
852855
</Docs>
853856
</Member>
854857
<Member MemberName="CreateVersion7">
@@ -876,10 +879,14 @@
876879
<Parameter Name="timestamp" Type="System.DateTimeOffset" Index="0" FrameworkAlternate="net-9.0" />
877880
</Parameters>
878881
<Docs>
879-
<param name="timestamp">To be added.</param>
880-
<summary>To be added.</summary>
881-
<returns>To be added.</returns>
882-
<remarks>To be added.</remarks>
882+
<param name="timestamp">The date-time offset used to determine the Unix Epoch timestamp.</param>
883+
<summary>Creates a new <see cref="T:System.Guid" /> according to RFC 9562, following the Version 7 format.</summary>
884+
<returns>A new <see cref="T:System.Guid" /> according to RFC 9562, following the Version 7 format.</returns>
885+
<remarks>
886+
<para>This method seeds the rand_a and rand_b sub-fields with random data.</para>
887+
</remarks>
888+
<exception cref="T:System.ArgumentOutOfRangeException">
889+
<paramref name="timestamp" /> represents an offset prior to <see cref="F:System.DateTimeOffset.UnixEpoch" />.</exception>
883890
</Docs>
884891
</Member>
885892
<Member MemberName="Empty">
@@ -3011,9 +3018,12 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust
30113018
<ReturnType>System.Int32</ReturnType>
30123019
</ReturnValue>
30133020
<Docs>
3014-
<summary>To be added.</summary>
3021+
<summary>Gets the value of the variant field for the <see cref="T:System.Guid" />.</summary>
30153022
<value>To be added.</value>
3016-
<remarks>To be added.</remarks>
3023+
<remarks>
3024+
<para>This property corresponds to the most significant 4 bits of the 8th byte: 00000000-0000-0000-F000-000000000000. The "don't-care" bits are not masked out.</para>
3025+
<para>For more information on how to interpret this value, see <see href="https://www.rfc-editor.org/rfc/rfc9562.html">RFC 9562</see>.</para>
3026+
</remarks>
30173027
</Docs>
30183028
</Member>
30193029
<Member MemberName="Version">
@@ -3038,9 +3048,12 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust
30383048
<ReturnType>System.Int32</ReturnType>
30393049
</ReturnValue>
30403050
<Docs>
3041-
<summary>To be added.</summary>
3051+
<summary>Gets the value of the version field for the <see cref="T:System.Guid" />.</summary>
30423052
<value>To be added.</value>
3043-
<remarks>To be added.</remarks>
3053+
<remarks>
3054+
<para>This property corresponds to the most significant 4 bits of the 6th byte: 00000000-0000-F000-0000-000000000000.</para>
3055+
<para>For more information on how to interpret this value, see <see href="https://www.rfc-editor.org/rfc/rfc9562.html">RFC 9562</see>.</para>
3056+
</remarks>
30443057
</Docs>
30453058
</Member>
30463059
</Members>

xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
</Attributes>
3636
<Docs>
3737
<typeparam name="T">To be added.</typeparam>
38-
<summary>To be added.</summary>
38+
<summary>Enables enumerating each split within a <see cref="T:System.ReadOnlySpan`1" /> that has been divided using one or more separators.</summary>
3939
<remarks>To be added.</remarks>
4040
</Docs>
4141
<Members>
@@ -61,8 +61,8 @@
6161
<ReturnType>System.Range</ReturnType>
6262
</ReturnValue>
6363
<Docs>
64-
<summary>To be added.</summary>
65-
<value>To be added.</value>
64+
<summary>Gets the current element of the enumeration.</summary>
65+
<value>A <see cref="T:System.Range" /> instance that indicates the bounds of the current element withing the source span.</value>
6666
<remarks>To be added.</remarks>
6767
</Docs>
6868
</Member>
@@ -89,8 +89,8 @@
8989
</ReturnValue>
9090
<Parameters />
9191
<Docs>
92-
<summary>To be added.</summary>
93-
<returns>To be added.</returns>
92+
<summary>Gets an enumerator that allows for iteration over the split span.</summary>
93+
<returns>A <see cref="T:System.MemoryExtensions.SpanSplitEnumerator`1" /> that can be used to iterate over the split span.</returns>
9494
<remarks>To be added.</remarks>
9595
</Docs>
9696
</Member>
@@ -111,8 +111,9 @@
111111
</ReturnValue>
112112
<Parameters />
113113
<Docs>
114-
<summary>To be added.</summary>
115-
<returns>To be added.</returns>
114+
<summary>Advances the enumerator to the next element of the enumeration.</summary>
115+
<returns>
116+
<see langword="true" /> if the enumerator was successfully advanced to the next element; <see langword="false" /> if the enumerator has passed the end of the enumeration.</returns>
116117
<remarks>To be added.</remarks>
117118
</Docs>
118119
</Member>

xml/System/MemoryExtensions.xml

Lines changed: 35 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9333,11 +9333,13 @@ Invalid sequences will be represented in the enumeration by <xref:System.Text.Ru
93339333
</Parameter>
93349334
</Parameters>
93359335
<Docs>
9336-
<typeparam name="T">To be added.</typeparam>
9337-
<param name="source">To be added.</param>
9338-
<param name="separator">To be added.</param>
9339-
<summary>To be added.</summary>
9340-
<returns>To be added.</returns>
9336+
<typeparam name="T">The type of the elements.</typeparam>
9337+
<param name="source">The source span to be enumerated.</param>
9338+
<param name="separator">The separator span to be used to split the provided span.</param>
9339+
<summary>
9340+
<para>Returns a type that allows for enumeration of each element within a split span using the provided separator span.</para>
9341+
</summary>
9342+
<returns>An enumerator that can be used to enumerate each element in a split span using the provided separator span.</returns>
93419343
<remarks>To be added.</remarks>
93429344
</Docs>
93439345
</Member>
@@ -9396,11 +9398,13 @@ Invalid sequences will be represented in the enumeration by <xref:System.Text.Ru
93969398
<Parameter Name="separator" Type="T" Index="1" FrameworkAlternate="net-9.0" />
93979399
</Parameters>
93989400
<Docs>
9399-
<typeparam name="T">To be added.</typeparam>
9400-
<param name="source">To be added.</param>
9401-
<param name="separator">To be added.</param>
9402-
<summary>To be added.</summary>
9403-
<returns>To be added.</returns>
9401+
<typeparam name="T">The type of the elements.</typeparam>
9402+
<param name="source">The source span to be enumerated.</param>
9403+
<param name="separator">The separator character to be used to split the provided span.</param>
9404+
<summary>
9405+
<para>Returns a type that allows for enumeration of each element within a split span using the provided separator character.</para>
9406+
</summary>
9407+
<returns>An enumerator that can be used to enumerate each element in a split span using the provided separator character.</returns>
94049408
<remarks>To be added.</remarks>
94059409
</Docs>
94069410
</Member>
@@ -9552,12 +9556,17 @@ Invalid sequences will be represented in the enumeration by <xref:System.Text.Ru
95529556
<Parameter Name="separators" Type="System.Buffers.SearchValues&lt;T&gt;" Index="1" FrameworkAlternate="net-9.0" />
95539557
</Parameters>
95549558
<Docs>
9555-
<typeparam name="T">To be added.</typeparam>
9556-
<param name="source">To be added.</param>
9557-
<param name="separators">To be added.</param>
9558-
<summary>To be added.</summary>
9559-
<returns>To be added.</returns>
9560-
<remarks>To be added.</remarks>
9559+
<typeparam name="T">The type of the elements.</typeparam>
9560+
<param name="source">The source span to be enumerated.</param>
9561+
<param name="separators">The <see cref="T:System.Buffers.SearchValues`1" /> to be used to split the provided span.</param>
9562+
<summary>
9563+
<para>Returns a type that allows for enumeration of each element within a split span using the provided separator characters.</para>
9564+
</summary>
9565+
<returns>An enumerator that can be used to enumerate each element in a split span using the provided separator characters.</returns>
9566+
<remarks>
9567+
<para>Unlike <see cref="M:System.MemoryExtensions.SplitAny``1(System.ReadOnlySpan{``0},System.ReadOnlySpan{``0})" />, <paramref name="separators" /> is not checked for being empty.</para>
9568+
<para>An empty <paramref name="separators" /> argument will result in no separators being found, regardless of the type of <typeparamref name="T" />, whereas <see cref="M:System.MemoryExtensions.SplitAny``1(System.ReadOnlySpan{``0},System.ReadOnlySpan{``0})" /> uses all Unicode whitespace characters as separators if <paramref name="separators" /> is empty and <typeparamref name="T" /> is <see cref="T:System.Char" />.</para>
9569+
</remarks>
95619570
</Docs>
95629571
</Member>
95639572
<Member MemberName="SplitAny&lt;T&gt;">
@@ -9618,12 +9627,16 @@ Invalid sequences will be represented in the enumeration by <xref:System.Text.Ru
96189627
</Parameter>
96199628
</Parameters>
96209629
<Docs>
9621-
<typeparam name="T">To be added.</typeparam>
9622-
<param name="source">To be added.</param>
9623-
<param name="separators">To be added.</param>
9624-
<summary>To be added.</summary>
9625-
<returns>To be added.</returns>
9626-
<remarks>To be added.</remarks>
9630+
<typeparam name="T">The type of the elements.</typeparam>
9631+
<param name="source">The source span to be enumerated.</param>
9632+
<param name="separators">The separators to be used to split the provided span.</param>
9633+
<summary>
9634+
<para>Returns a type that allows for enumeration of each element within a split span using any of the provided elements.</para>
9635+
</summary>
9636+
<returns>An enumerator that can be used to enumerate each element in a split span using the provided separator characters.</returns>
9637+
<remarks>
9638+
<para>If <typeparamref name="T" /> is <see cref="T:System.Char" /> and if <paramref name="separators" /> is empty, all Unicode whitespace characters are used as the separators. This matches the behavior of when <see cref="M:System.String.Split(System.Char[])" /> and related overloads are used with an empty separator array, or when <see cref="M:System.MemoryExtensions.SplitAny(System.ReadOnlySpan{System.Char},System.Span{System.Range},System.ReadOnlySpan{System.Char},System.StringSplitOptions)" /> is used with an empty separator span.</para>
9639+
</remarks>
96279640
</Docs>
96289641
</Member>
96299642
<Member MemberName="StartsWith">

0 commit comments

Comments
 (0)