From 6dc8349c109d31bd23eebd8f4c8708b4cbe2c815 Mon Sep 17 00:00:00 2001 From: Tanner Gooding Date: Wed, 4 Sep 2024 10:26:36 -0700 Subject: [PATCH 1/2] Updating the documentation for System.Runtime --- xml/System/Environment+ProcessCpuUsage.xml | 12 ++-- xml/System/Environment.xml | 4 +- xml/System/Guid.xml | 39 ++++++++---- ...MemoryExtensions+SpanSplitEnumerator`1.xml | 15 ++--- xml/System/MemoryExtensions.xml | 57 +++++++++++------- xml/System/TimeSpan.xml | 60 +++++++++---------- 6 files changed, 109 insertions(+), 78 deletions(-) diff --git a/xml/System/Environment+ProcessCpuUsage.xml b/xml/System/Environment+ProcessCpuUsage.xml index 73212899ff3..5ac93cc3376 100644 --- a/xml/System/Environment+ProcessCpuUsage.xml +++ b/xml/System/Environment+ProcessCpuUsage.xml @@ -28,8 +28,10 @@ - To be added. - To be added. + Represents the CPU usage statistics of a process. + + 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. + @@ -48,7 +50,7 @@ System.TimeSpan - To be added. + Gets the amount of time the process has spent running code inside the operating system code. To be added. To be added. @@ -69,7 +71,7 @@ System.TimeSpan - To be added. + Gets the amount of time the process has spent utilizing the CPU including the process time spent in the application code and the process time spent in the operating system code. To be added. To be added. @@ -90,7 +92,7 @@ System.TimeSpan - To be added. + Gets the amount of time the associated process has spent running code inside the application portion of the process (not the operating system code). To be added. To be added. diff --git a/xml/System/Environment.xml b/xml/System/Environment.xml index 49d271cc09a..98ce8bf1ca9 100644 --- a/xml/System/Environment.xml +++ b/xml/System/Environment.xml @@ -202,7 +202,9 @@ System.Environment+ProcessCpuUsage - To be added. + + 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. + To be added. To be added. diff --git a/xml/System/Guid.xml b/xml/System/Guid.xml index c48d15b3198..2f1247b2eb4 100644 --- a/xml/System/Guid.xml +++ b/xml/System/Guid.xml @@ -603,9 +603,9 @@ System.Guid - To be added. + Gets a where all bits are set. To be added. - To be added. + This returns the value: FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFFF @@ -846,9 +846,12 @@ - To be added. - To be added. - To be added. + Creates a new according to RFC 9562, following the Version 7 format. + A new according to RFC 9562, following the Version 7 format. + + This uses to determine the Unix Epoch timestamp source. + This seeds the rand_a and rand_b sub-fields with random data. + @@ -876,10 +879,14 @@ - To be added. - To be added. - To be added. - To be added. + The date time offset used to determine the Unix Epoch timestamp. + Creates a new according to RFC 9562, following the Version 7 format. + A new according to RFC 9562, following the Version 7 format. + + This seeds the rand_a and rand_b sub-fields with random data. + + + represents an offset prior to . @@ -3011,9 +3018,12 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust System.Int32 - To be added. + Gets the value of the variant field for the . To be added. - To be added. + + This 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. + See RFC 9562 for more information on how to interpret this value. + @@ -3038,9 +3048,12 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust System.Int32 - To be added. + Gets the value of the version field for the . To be added. - To be added. + + This corresponds to the most significant 4 bits of the 6th byte: 00000000-0000-F000-0000-000000000000. + See RFC 9562 for more information on how to interpret this value. + diff --git a/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml b/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml index 7718a94313f..5bec8a89de7 100644 --- a/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml +++ b/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml @@ -35,7 +35,7 @@ To be added. - To be added. + Enables enumerating each split within a that has been divided using one or more separators. To be added. @@ -61,8 +61,8 @@ System.Range - To be added. - To be added. + Gets the current element of the enumeration. + Returns a instance that indicates the bounds of the current element withing the source span. To be added. @@ -89,8 +89,8 @@ - To be added. - To be added. + Gets an enumerator that allows for iteration over the split span. + Returns a that can be used to iterate over the split span. To be added. @@ -111,8 +111,9 @@ - To be added. - To be added. + Advances the enumerator to the next element of the enumeration. + + if the enumerator was successfully advanced to the next element; if the enumerator has passed the end of the enumeration. To be added. diff --git a/xml/System/MemoryExtensions.xml b/xml/System/MemoryExtensions.xml index 71ad0803823..b21bfd4f515 100644 --- a/xml/System/MemoryExtensions.xml +++ b/xml/System/MemoryExtensions.xml @@ -9333,11 +9333,13 @@ Invalid sequences will be represented in the enumeration by - To be added. - To be added. - To be added. - To be added. - To be added. + The type of the elements. + The source span to be enumerated. + The separator span to be used to split the provided span. + + Returns a type that allows for enumeration of each element within a split span using the provided separator span. + + Returns a . To be added. @@ -9396,11 +9398,13 @@ Invalid sequences will be represented in the enumeration by - To be added. - To be added. - To be added. - To be added. - To be added. + The type of the elements. + The source span to be enumerated. + The separator character to be used to split the provided span. + + Returns a type that allows for enumeration of each element within a split span using the provided separator character. + + Returns a . To be added. @@ -9552,12 +9556,17 @@ Invalid sequences will be represented in the enumeration by - To be added. - To be added. - To be added. - To be added. - To be added. - To be added. + The type of the elements. + The source span to be enumerated. + The to be used to split the provided span. + + Returns a type that allows for enumeration of each element within a split span using the provided . + + Returns a . + + Unlike , the is not checked for being empty. + An empty will result in no separators being found, regardless of the type of , whereas will use all Unicode whitespace characters as separators if is empty and is . + @@ -9618,12 +9627,16 @@ Invalid sequences will be represented in the enumeration by - To be added. - To be added. - To be added. - To be added. - To be added. - To be added. + The type of the elements. + The source span to be enumerated. + The separators to be used to split the provided span. + + Returns a type that allows for enumeration of each element within a split span using any of the provided elements. + + Returns a . + + If is and if is empty, all Unicode whitespace characters are used as the separators. This matches the behavior of when and related overloads are used with an empty separator array, or when is used with an empty separator span. + diff --git a/xml/System/TimeSpan.xml b/xml/System/TimeSpan.xml index 2e78a010ae0..2854e312353 100644 --- a/xml/System/TimeSpan.xml +++ b/xml/System/TimeSpan.xml @@ -2310,8 +2310,8 @@ The specified `days`, `hours`, `minutes`, `seconds`, `milliseconds`, and `micros 24 - To be added. - To be added. + Represents the number of hours in 1 day. This field is constant. + The value of this constant is 24. @@ -2437,8 +2437,8 @@ The property represents whole microseconds, 86400000000 - To be added. - To be added. + Represents the number of microseconds in 1 day. This field is constant. + The value of this constant is 86.4 billion; that is, 86,400,000,000. @@ -2464,8 +2464,8 @@ The property represents whole microseconds, 3600000000 - To be added. - To be added. + Represents the number of microseconds in 1 hour. This field is constant. + The value of this constant is 3.6 billion; that is, 3,600,000,000. @@ -2491,8 +2491,8 @@ The property represents whole microseconds, 1000 - To be added. - To be added. + Represents the number of microseconds in 1 millisecond. This field is constant. + The value of this constant is 1 thousand; that is, 1,000. @@ -2518,8 +2518,8 @@ The property represents whole microseconds, 60000000 - To be added. - To be added. + Represents the number of microseconds in 1 minute. This field is constant. + The value of this constant is 60 million; that is, 60,000,000. @@ -2545,8 +2545,8 @@ The property represents whole microseconds, 1000000 - To be added. - To be added. + Represents the number of microseconds in 1 second. This field is constant. + The value of this constant is 1 million; that is, 1,000,000. @@ -2641,8 +2641,8 @@ The property represents whole microseconds, 86400000 - To be added. - To be added. + Represents the number of milliseconds in 1 day. This field is constant. + The value of this constant is 86.4 million; that is, 86,400,000. @@ -2668,8 +2668,8 @@ The property represents whole microseconds, 3600000 - To be added. - To be added. + Represents the number of milliseconds in 1 hour. This field is constant. + The value of this constant is 3.6 million; that is, 3,600,000. @@ -2695,8 +2695,8 @@ The property represents whole microseconds, 60000 - To be added. - To be added. + Represents the number of milliseconds in 1 minute. This field is constant. + The value of this constant is 60 thousand; that is, 60,000. @@ -2722,8 +2722,8 @@ The property represents whole microseconds, 1000 - To be added. - To be added. + Represents the number of milliseconds in 1 second. This field is constant. + The value of this constant is 1 thousand; that is, 1,000. @@ -2818,8 +2818,8 @@ The property represents whole microseconds, 1440 - To be added. - To be added. + Represents the number of minutes in 1 day. This field is constant. + The value of this constant is 1440. @@ -2845,8 +2845,8 @@ The property represents whole microseconds, 60 - To be added. - To be added. + Represents the number of minutes in 1 hour. This field is constant. + The value of this constant is 60. @@ -4874,8 +4874,8 @@ The following example defines an array of 86400 - To be added. - To be added. + Represents the number of seconds in 1 day. This field is constant. + The value of this constant is 86.4 thousand; that is, 86,400. @@ -4901,8 +4901,8 @@ The following example defines an array of 3600 - To be added. - To be added. + Represents the number of seconds in 1 hour. This field is constant. + The value of this constant is 3.6 thousand; that is, 3,600. @@ -4928,8 +4928,8 @@ The following example defines an array of 60 - To be added. - To be added. + Represents the number of seconds in 1 minute. This field is constant. + The value of this constant is 60. From cfc4d2e9b17be72674d52e8a2dbd492c6b3ddcea Mon Sep 17 00:00:00 2001 From: Tanner Gooding Date: Wed, 4 Sep 2024 11:23:07 -0700 Subject: [PATCH 2/2] Apply suggestions from code review Co-authored-by: Genevieve Warren <24882762+gewarren@users.noreply.github.com> --- xml/System/Environment+ProcessCpuUsage.xml | 2 +- xml/System/Guid.xml | 20 +++++++++---------- ...MemoryExtensions+SpanSplitEnumerator`1.xml | 4 ++-- xml/System/MemoryExtensions.xml | 16 +++++++-------- 4 files changed, 21 insertions(+), 21 deletions(-) diff --git a/xml/System/Environment+ProcessCpuUsage.xml b/xml/System/Environment+ProcessCpuUsage.xml index 5ac93cc3376..209a8fc87dc 100644 --- a/xml/System/Environment+ProcessCpuUsage.xml +++ b/xml/System/Environment+ProcessCpuUsage.xml @@ -71,7 +71,7 @@ System.TimeSpan - Gets the amount of time the process has spent utilizing the CPU including the process time spent in the application code and the process time spent in the operating system code. + 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. To be added. To be added. diff --git a/xml/System/Guid.xml b/xml/System/Guid.xml index 2f1247b2eb4..3a7cfb97b63 100644 --- a/xml/System/Guid.xml +++ b/xml/System/Guid.xml @@ -604,8 +604,8 @@ Gets a where all bits are set. - To be added. - This returns the value: FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFFF + A GUID with a value of FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFFF. + To be added. @@ -849,8 +849,8 @@ Creates a new according to RFC 9562, following the Version 7 format. A new according to RFC 9562, following the Version 7 format. - This uses to determine the Unix Epoch timestamp source. - This seeds the rand_a and rand_b sub-fields with random data. + This method uses to determine the Unix Epoch timestamp source. + This method seeds the rand_a and rand_b sub-fields with random data. @@ -879,11 +879,11 @@ - The date time offset used to determine the Unix Epoch timestamp. + The date-time offset used to determine the Unix Epoch timestamp. Creates a new according to RFC 9562, following the Version 7 format. A new according to RFC 9562, following the Version 7 format. - This seeds the rand_a and rand_b sub-fields with random data. + This method seeds the rand_a and rand_b sub-fields with random data. represents an offset prior to . @@ -3021,8 +3021,8 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust Gets the value of the variant field for the . To be added. - This 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. - See RFC 9562 for more information on how to interpret this value. + 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. + For more information on how to interpret this value, see RFC 9562. @@ -3051,8 +3051,8 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust Gets the value of the version field for the . To be added. - This corresponds to the most significant 4 bits of the 6th byte: 00000000-0000-F000-0000-000000000000. - See RFC 9562 for more information on how to interpret this value. + This property corresponds to the most significant 4 bits of the 6th byte: 00000000-0000-F000-0000-000000000000. + For more information on how to interpret this value, see RFC 9562. diff --git a/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml b/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml index 5bec8a89de7..e5b4cd8df4d 100644 --- a/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml +++ b/xml/System/MemoryExtensions+SpanSplitEnumerator`1.xml @@ -62,7 +62,7 @@ Gets the current element of the enumeration. - Returns a instance that indicates the bounds of the current element withing the source span. + A instance that indicates the bounds of the current element withing the source span. To be added. @@ -90,7 +90,7 @@ Gets an enumerator that allows for iteration over the split span. - Returns a that can be used to iterate over the split span. + A that can be used to iterate over the split span. To be added. diff --git a/xml/System/MemoryExtensions.xml b/xml/System/MemoryExtensions.xml index b21bfd4f515..691b81a1a57 100644 --- a/xml/System/MemoryExtensions.xml +++ b/xml/System/MemoryExtensions.xml @@ -9339,7 +9339,7 @@ Invalid sequences will be represented in the enumeration by Returns a type that allows for enumeration of each element within a split span using the provided separator span. - Returns a . + An enumerator that can be used to enumerate each element in a split span using the provided separator span. To be added. @@ -9404,7 +9404,7 @@ Invalid sequences will be represented in the enumeration by Returns a type that allows for enumeration of each element within a split span using the provided separator character. - Returns a . + An enumerator that can be used to enumerate each element in a split span using the provided separator character. To be added. @@ -9558,14 +9558,14 @@ Invalid sequences will be represented in the enumeration by The type of the elements. The source span to be enumerated. - The to be used to split the provided span. + The to be used to split the provided span. - Returns a type that allows for enumeration of each element within a split span using the provided . + Returns a type that allows for enumeration of each element within a split span using the provided separator characters. - Returns a . + An enumerator that can be used to enumerate each element in a split span using the provided separator characters. - Unlike , the is not checked for being empty. - An empty will result in no separators being found, regardless of the type of , whereas will use all Unicode whitespace characters as separators if is empty and is . + Unlike , is not checked for being empty. + An empty argument will result in no separators being found, regardless of the type of , whereas uses all Unicode whitespace characters as separators if is empty and is . @@ -9633,7 +9633,7 @@ Invalid sequences will be represented in the enumeration by Returns a type that allows for enumeration of each element within a split span using any of the provided elements. - Returns a . + An enumerator that can be used to enumerate each element in a split span using the provided separator characters. If is and if is empty, all Unicode whitespace characters are used as the separators. This matches the behavior of when and related overloads are used with an empty separator array, or when is used with an empty separator span.