diff --git a/xml/System/Activator.xml b/xml/System/Activator.xml index 2c19672e12c..68c335a63a1 100644 --- a/xml/System/Activator.xml +++ b/xml/System/Activator.xml @@ -181,7 +181,7 @@ -or- - was not found in . + was not found in . No matching constructor was found. is not found, or the module you are trying to load does not specify a file name extension. @@ -272,7 +272,7 @@ -or- - was not found in . + was not found in . No matching constructor was found. An instance of an abstract class cannot be created. @@ -604,7 +604,7 @@ Note: In .NET for Win is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -914,7 +914,7 @@ Note: In .NET for Win or is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -1016,7 +1016,7 @@ Note: In .NET for Win is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -1503,7 +1503,7 @@ An error occurred when attempting remote activation in a target specified in is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -1599,7 +1599,7 @@ An error occurred when attempting remote activation in a target specified in or is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -1702,7 +1702,7 @@ An error occurred when attempting remote activation in a target specified in is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -1803,7 +1803,7 @@ An error occurred when attempting remote activation in a target specified in or is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2002,7 +2002,7 @@ Note: In .NET for Win is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2014,7 +2014,7 @@ Note: In .NET for Win -or- - The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. + The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. @@ -2072,7 +2072,7 @@ Note: In .NET for Win or is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2084,7 +2084,7 @@ Note: In .NET for Win -or- - The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. + The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. @@ -2163,7 +2163,7 @@ Note: In .NET for Win is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2177,7 +2177,7 @@ Note: In .NET for Win -or- - The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. + The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. @@ -2272,7 +2272,7 @@ Note: In .NET for Win is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2286,7 +2286,7 @@ Note: In .NET for Win -or- - The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. + The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. @@ -2358,7 +2358,7 @@ Note: In .NET for Win or is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2372,7 +2372,7 @@ Note: In .NET for Win -or- - was compiled for a version of the common language runtime that is later than the version that is currently loaded. + was compiled for a version of the common language runtime that is later than the version that is currently loaded. @@ -2444,7 +2444,7 @@ Note: In .NET for Win is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2458,7 +2458,7 @@ Note: In .NET for Win -or- - The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. + The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. @@ -2537,7 +2537,7 @@ Note: In .NET for Win or is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2551,7 +2551,7 @@ Note: In .NET for Win -or- - The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. + The common language runtime (CLR) version 2.0 or later is currently loaded, and was compiled for a version of the CLR that is later than the currently loaded version. Note that the .NET Framework versions 2.0, 3.0, and 3.5 all use CLR version 2.0. diff --git a/xml/System/AppDomain.xml b/xml/System/AppDomain.xml index 551fa349c28..806285f3dcd 100644 --- a/xml/System/AppDomain.xml +++ b/xml/System/AppDomain.xml @@ -978,7 +978,7 @@ Application domains, which are represented by objects, h ]]> - or is . + or is . The type cannot be loaded. The operation is attempted on an unloaded application domain. No public parameterless constructor was found. @@ -1540,7 +1540,7 @@ This method overload uses the information from the The caller does not have permission to call this constructor. No matching public constructor was found. - was not found in . + was not found in . This instance is . @@ -1641,7 +1641,7 @@ This method overload uses the information from the No matching public constructor was found. The caller cannot provide activation attributes for an object that does not inherit from . - was not found in . + was not found in . This instance is . @@ -1753,7 +1753,7 @@ This method overload uses the information from the No matching constructor was found. The caller cannot provide activation attributes for an object that does not inherit from . - was not found in . + was not found in . This instance is . @@ -1849,7 +1849,7 @@ This method overload uses the information from the is not . When legacy CAS policy is not enabled, should be - was not found in . + was not found in . This instance is . @@ -1948,7 +1948,7 @@ This method overload uses the information from the or is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2050,7 +2050,7 @@ This method overload uses the information from the or is . No matching public constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2174,7 +2174,7 @@ This method overload uses the information from the or is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -2275,7 +2275,7 @@ This method overload uses the information from the or is . No matching constructor was found. - was not found in . + was not found in . was not found. The caller does not have permission to call this constructor. @@ -3046,7 +3046,7 @@ This method overload uses the information from the ]]> - is . + is . -or- @@ -3054,17 +3054,17 @@ This method overload uses the information from the The caller cannot provide activation attributes for an object that does not inherit from . The operation is attempted on an unloaded application domain. - was not found. + was not found. - was not found in . + was not found in . No matching public constructor was found. The caller does not have sufficient permission to call this constructor. - is not a valid assembly. + is not a valid assembly. -or- - was compiled with a later version of the common language runtime that the version that is currently loaded. + was compiled with a later version of the common language runtime that the version that is currently loaded. An assembly or module was loaded twice with two different evidences. diff --git a/xml/System/ArgumentException.xml b/xml/System/ArgumentException.xml index 8ba99c26891..0b2fe960088 100644 --- a/xml/System/ArgumentException.xml +++ b/xml/System/ArgumentException.xml @@ -650,13 +650,13 @@ The following example demonstrates how to throw and catch an Value - The is a null reference ( in Visual Basic) or of zero length. + The is a null reference ( in Visual Basic) or of zero length. - The string passed to the constructor. + The string passed to the constructor. - The is not null reference ( in Visual Basic) and it has a length greater than zero. + The is not null and has a length greater than zero. - The string appended with the name of the invalid parameter. + The string appended with the name of the invalid parameter. diff --git a/xml/System/ArgumentOutOfRangeException.xml b/xml/System/ArgumentOutOfRangeException.xml index 9b9b4516bd2..aa6cbe6e925 100644 --- a/xml/System/ArgumentOutOfRangeException.xml +++ b/xml/System/ArgumentOutOfRangeException.xml @@ -848,13 +848,13 @@ The following example defines a class to contain information about an invited gu Value - The is . + The is . - The string passed to the constructor. + The string passed to the constructor. - The is not . + The is not . - The string appended with the string representation of the invalid argument value. + The string appended with the string representation of the invalid argument value. diff --git a/xml/System/Array.xml b/xml/System/Array.xml index 6ad88ada2e4..9b20b843014 100644 --- a/xml/System/Array.xml +++ b/xml/System/Array.xml @@ -819,7 +819,7 @@ is . - does not implement the generic interface. + does not implement the generic interface. Performing Culture-Insensitive String Operations in Arrays @@ -954,7 +954,7 @@ is , and is of a type that is not compatible with the elements of . - is , and does not implement the generic interface + is , and does not implement the generic interface @@ -1064,7 +1064,7 @@ is of a type that is not compatible with the elements of . - does not implement the generic interface. + does not implement the generic interface. Performing Culture-Insensitive String Operations in Arrays @@ -1195,7 +1195,7 @@ is , and is of a type that is not compatible with the elements of . - is , and does not implement the generic interface. + is , and does not implement the generic interface. @@ -3475,7 +3475,7 @@ The one-dimensional, zero-based array to search. The predicate that defines the conditions of the element to search for. Searches for an element that matches the conditions defined by the specified predicate, and returns the first occurrence within the entire . - The first element that matches the conditions defined by the specified predicate, if found; otherwise, the default value for type . + The first element that matches the conditions defined by the specified predicate, if found; otherwise, the default value for type . The one-dimensional, zero-based to search. The that defines the conditions of the element to search for. Searches for an element that matches the conditions defined by the specified predicate, and returns the last occurrence within the entire . - The last element that matches the conditions defined by the specified predicate, if found; otherwise, the default value for type . + The last element that matches the conditions defined by the specified predicate, if found; otherwise, the default value for type . The type of the elements in the array segment. Delimits a section of a one-dimensional array. - is a wrapper around an array that delimits a range of elements in that array. Multiple instances can refer to the same original array and can overlap. The original array must be one-dimensional and must have zero-based indexing. - + is a wrapper around an array that delimits a range of elements in that array. Multiple instances can refer to the same original array and can overlap. The original array must be one-dimensional and must have zero-based indexing. + > [!NOTE] -> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the structure did not implement this interface. - - The structure is useful whenever the elements of an array will be manipulated in distinct segments. For example: - -- You can pass an object that represents only a portion of an array as an argument to a method, rather than call a relatively expensive method like to pass a copy of a portion of an array. - -- In a multithreaded app, you can use the structure to have each thread operate on only a portion of the array. - -- For task-based asynchronous operations, you can use an object to ensure that each task operates on a distinct segment of the array. The following example divides an array into individual segments with up to ten elements. Each element in the segment is multiplied by its segment number. The result shows that using the class to manipulate elements in this way changes the values of its underlying array. - +> implements the interface starting with the .NET Framework 4.6; in previous versions of the .NET Framework, the structure did not implement this interface. + + The structure is useful whenever the elements of an array will be manipulated in distinct segments. For example: + +- You can pass an object that represents only a portion of an array as an argument to a method, rather than call a relatively expensive method like to pass a copy of a portion of an array. + +- In a multithreaded app, you can use the structure to have each thread operate on only a portion of the array. + +- For task-based asynchronous operations, you can use an object to ensure that each task operates on a distinct segment of the array. The following example divides an array into individual segments with up to ten elements. Each element in the segment is multiplied by its segment number. The result shows that using the class to manipulate elements in this way changes the values of its underlying array. + :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/segmentexample.cs" id="Snippet2"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.ArraySegment/FS/segmentexample.fs" id="Snippet2"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/segmentexample.vb" id="Snippet2"::: - - Note, however, that although the structure can be used to divide an array into distinct segments, the segments are not completely independent of one another. The property returns the entire original array, not a copy of the array; therefore, changes made to the array returned by the property are made to the original array. If this is undesirable, you should perform operations on a copy of the array, rather than an object that represents a portion of the array. - - The method and the equality and inequality operators test for reference equality when they compare two objects. For two objects to be considered equal, they must meet all of the following conditions: - -- Reference the same array. - -- Begin at the same index in the array. - -- Have the same number of elements. - - If you want to retrieve an element by its index in the object, you must cast it to an object and retrieve it or modify it by using the property. Note that this is not necessary in F#. The following example retrieves the element in an object that delimits a section of a string array. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/segmentexample.vb" id="Snippet2"::: + + Note, however, that although the structure can be used to divide an array into distinct segments, the segments are not completely independent of one another. The property returns the entire original array, not a copy of the array; therefore, changes made to the array returned by the property are made to the original array. If this is undesirable, you should perform operations on a copy of the array, rather than an object that represents a portion of the array. + + The method and the equality and inequality operators test for reference equality when they compare two objects. For two objects to be considered equal, they must meet all of the following conditions: + +- Reference the same array. + +- Begin at the same index in the array. + +- Have the same number of elements. + + If you want to retrieve an element by its index in the object, you must cast it to an object and retrieve it or modify it by using the property. Note that this is not necessary in F#. The following example retrieves the element in an object that delimits a section of a string array. + :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/example1.cs" interactive="try-dotnet" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.arraysegment.class/fs/example1.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.arraysegment.class/vb/example1.vb" id="Snippet1"::: + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.arraysegment.class/vb/example1.vb" id="Snippet1"::: + + + +## Examples + The following code example passes an structure to a method. - - -## Examples - The following code example passes an structure to a method. - :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.ArraySegment/CPP/arraysegment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/arraysegment.cs" interactive="try-dotnet" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.ArraySegment/FS/arraysegment.fs" id="Snippet1"::: @@ -167,16 +167,16 @@ Initializes a new instance of the structure. - structure to a method. - + structure to a method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.ArraySegment/CPP/arraysegment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/arraysegment.cs" interactive="try-dotnet" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.ArraySegment/FS/arraysegment.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: + ]]> @@ -222,15 +222,15 @@ The array to wrap. Initializes a new instance of the structure that delimits all the elements in the specified array. - that delimits all the elements of `array`. That is, the property of the is 0 and its property is the length of `array`. To create an that delimits only part of an array, use the constructor. - - The original array must be one-dimensional and must have zero-based indexing. - - Multiple instances can refer to the same original array and can overlap. - + that delimits all the elements of `array`. That is, the property of the is 0 and its property is the length of `array`. To create an that delimits only part of an array, use the constructor. + + The original array must be one-dimensional and must have zero-based indexing. + + Multiple instances can refer to the same original array and can overlap. + ]]> @@ -283,12 +283,12 @@ The number of elements in the range. Initializes a new instance of the structure that delimits the specified range of the elements in the specified array. - instances can refer to the same original array and can overlap. + instances can refer to the same original array and can overlap. ]]> @@ -349,21 +349,21 @@ Gets the original array containing the range of elements that the array segment delimits. The original array that was passed to the constructor, and that contains the range delimited by the . - property returns the original array, not a copy of the array; therefore, changes made through the property are made directly to the original array. - - - -## Examples - The following code example passes an to a method. - + property returns the original array, not a copy of the array; therefore, changes made through the property are made directly to the original array. + + + +## Examples + The following code example passes an to a method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.ArraySegment/CPP/arraysegment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/arraysegment.cs" interactive="try-dotnet" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.ArraySegment/FS/arraysegment.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: + ]]> @@ -416,7 +416,7 @@ -or- -The underlying array of is . +The underlying array of is . The length of the underlying array of this instance is larger than the length of the underlying array of . @@ -454,7 +454,7 @@ The underlying array of is - The array of type into which the contents of this instance will be copied. + The array of type into which the contents of this instance will be copied. Copies the contents of this instance into the specified destination array of the same type . To be added. The underlying array of this instance is . @@ -500,7 +500,7 @@ The underlying array of is - The array of type into which the contents of this instance will be copied. + The array of type into which the contents of this instance will be copied. The index in at which storing begins. Copies the contents of this instance into the specified destination array of the same type , starting at the specified destination index. To be added. @@ -552,16 +552,16 @@ The underlying array of is Gets the number of elements in the range delimited by the array segment. The number of elements in the range delimited by the . - structure to a method. - + structure to a method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.ArraySegment/CPP/arraysegment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/arraysegment.cs" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.ArraySegment/FS/arraysegment.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: + ]]> @@ -675,17 +675,17 @@ The underlying array of is if the specified structure is equal to the current instance; otherwise, . - objects are considered to be equal if all the following conditions are met: - -- They reference the same array. - -- They begin at the same index in the array. - -- They have the same number of elements. - + objects are considered to be equal if all the following conditions are met: + +- They reference the same array. + +- They begin at the same index in the array. + +- They have the same number of elements. + ]]> @@ -750,17 +750,17 @@ The underlying array of is if the specified object is a structure and is equal to the current instance; otherwise, . - objects are considered to be equal if all the following conditions are met: - -- They reference the same array. - -- They begin at the same index in the array. - -- They have the same number of elements. - + objects are considered to be equal if all the following conditions are met: + +- They reference the same array. + +- They begin at the same index in the array. + +- They have the same number of elements. + ]]> @@ -931,16 +931,16 @@ The underlying array of is Gets the position of the first element in the range delimited by the array segment, relative to the start of the original array. The position of the first element in the range delimited by the , relative to the start of the original array. - structure to a method. - + structure to a method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR_System/system.ArraySegment/CPP/arraysegment.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/arraysegment.cs" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.ArraySegment/FS/arraysegment.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.ArraySegment/VB/arraysegment.vb" id="Snippet1"::: + ]]> @@ -1009,17 +1009,17 @@ The underlying array of is if is equal to ; otherwise, . - objects are considered to be equal if all the following conditions are met: - -- They reference the same array. - -- They begin at the same index. - -- They have the same number of elements. - + objects are considered to be equal if all the following conditions are met: + +- They reference the same array. + +- They begin at the same index. + +- They have the same number of elements. + The equivalent method for this operator is ]]> @@ -1125,17 +1125,17 @@ The underlying array of is if is not equal to ; otherwise, . - objects are considered to be unequal if they are of the same closed generic type but any of the following conditions is true: - -- They do not reference the same array. - -- They have different starting indexes. - -- They have a different number of elements. - + objects are considered to be unequal if they are of the same closed generic type but any of the following conditions is true: + +- They do not reference the same array. + +- They have different starting indexes. + +- They have a different number of elements. + The equivalent method for this operator is ]]> @@ -1373,11 +1373,11 @@ The underlying array of is if is found in the array segment; otherwise, . - instance is cast to an interface. - + instance is cast to an interface. + ]]> The underlying array is . @@ -1423,11 +1423,11 @@ The underlying array of is The zero-based index in at which copying begins. Copies the elements of the array segment to an array, starting at the specified array index. - instance is cast to an interface. - + instance is cast to an interface. + ]]> @@ -1435,15 +1435,15 @@ The underlying array of is is less than 0. - is multidimensional. - - -or- - - The number of elements in the source array segment is greater than the available space from to the end of the destination . - - -or- - - Type cannot be cast automatically to the type of the destination . + is multidimensional. + + -or- + + The number of elements in the source array segment is greater than the available space from to the end of the destination . + + -or- + + Type cannot be cast automatically to the type of the destination . The underlying array for this instance is . @@ -1491,11 +1491,11 @@ The underlying array of is if the array segment is read-only; otherwise, . - instance is cast to an interface. - + instance is cast to an interface. + ]]> @@ -1594,11 +1594,11 @@ The underlying array of is Returns an enumerator that iterates through the array segment. An enumerator that can be used to iterate through the array segment. - instance is cast to an interface. - + instance is cast to an interface. + ]]> The underlying array is . @@ -1651,11 +1651,11 @@ The underlying array of is Determines the index of a specific item in the array segment. The index of if found in the list; otherwise, -1. - instance is cast to an interface. - + instance is cast to an interface. + ]]> The underlying array is . @@ -1759,15 +1759,15 @@ The underlying array of is Gets or sets the element at the specified index. The element at the specified index. - instance is cast to an interface, as the following example shows. - + instance is cast to an interface, as the following example shows. + :::code language="csharp" source="~/snippets/csharp/System/ArraySegmentT/Overview/example1.cs" interactive="try-dotnet" id="Snippet1"::: :::code language="fsharp" source="~/snippets/fsharp/VS_Snippets_CLR_System/system.arraysegment.class/fs/example1.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.arraysegment.class/vb/example1.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.arraysegment.class/vb/example1.vb" id="Snippet1"::: + ]]> @@ -1871,11 +1871,11 @@ The underlying array of is Gets the element at the specified index of the array segment. The element at the specified index. - instance is cast to an interface. - + instance is cast to an interface. + ]]> @@ -1928,11 +1928,11 @@ The underlying array of is Returns an enumerator that iterates through an array segment. An enumerator that can be used to iterate through the array segment. - instance is cast to an interface. - + instance is cast to an interface. + ]]> The underlying array is . diff --git a/xml/System/Attribute.xml b/xml/System/Attribute.xml index 795691ebcf5..96681b0da42 100644 --- a/xml/System/Attribute.xml +++ b/xml/System/Attribute.xml @@ -1145,13 +1145,6 @@ When implementing your own class derived from , you can o [!NOTE] -> Starting with the .NET Framework version 2.0, this method returns security attributes if the attributes are stored in the new metadata format. Assemblies compiled with version 2.0 or later use the new format. Dynamic assemblies and assemblies compiled with earlier versions of the .NET Framework use the old XML format. See [Emitting Declarative Security Attributes](/previous-versions/dotnet/netframework-4.0/ms404249(v=vs.100)). - - - ## Examples The following code example demonstrates the use of , taking an as a parameter. @@ -1163,7 +1156,7 @@ When implementing your own class derived from , you can o ]]> - or is . + is . @@ -1368,7 +1361,7 @@ When implementing your own class derived from , you can o ]]> - or is . + is . diff --git a/xml/System/Convert.xml b/xml/System/Convert.xml index 56910cbef90..050da24eb84 100644 --- a/xml/System/Convert.xml +++ b/xml/System/Convert.xml @@ -1594,7 +1594,7 @@ A read-only span of 8-bit unsigned integers. One of the enumeration values that specify whether to insert line breaks in the return value. The default value is . Converts the 8-bit unsigned integers inside the specified read-only span into their equivalent string representation that is encoded with base-64 digits. You can optionally specify whether to insert line breaks in the return value. - The string representation in base 64 of the elements in . If the length of is 0, an empty string is returned. + The string representation in base 64 of the elements in . If the length of is 0, an empty string is returned. To be added. is not a valid value. @@ -22815,7 +22815,7 @@ A read-only span of 8-bit unsigned integers. - The span in which to write the string representation in base 64 of the elements in . If the length of is 0, or when this method returns , nothing is written into this parameter. + The span in which to write the string representation in base 64 of the elements in . If the length of is 0, or when this method returns , nothing is written into this parameter. When this method returns, contains the total number of characters written into . One of the enumeration values that specify whether to insert line breaks in the return value. The default value is . Tries to convert the 8-bit unsigned integers inside the specified read-only span into their equivalent string representation that is encoded with base-64 digits. You can optionally specify whether to insert line breaks in the return value. diff --git a/xml/System/DateTime.xml b/xml/System/DateTime.xml index f85aecf0547..8932d765742 100644 --- a/xml/System/DateTime.xml +++ b/xml/System/DateTime.xml @@ -10144,11 +10144,11 @@ The following example illustrates the - is not a valid value. + is not a valid value. -or- - contains an invalid combination of values (for example, both and ). + contains an invalid combination of values (for example, both and ). In the .NET Framework 4, the method returns if the string to be parsed contains an hour component and an AM/PM designator that are not in agreement. In the .NET Framework 3.5 and earlier versions, the AM/PM designator is ignored. @@ -10289,11 +10289,11 @@ The following example illustrates the - is not a valid value. + is not a valid value. -or- - contains an invalid combination of values (for example, both and ). + contains an invalid combination of values (for example, both and ). In the .NET Framework 4, the method returns if the string to be parsed contains an hour component and an AM/PM designator that are not in agreement. In the .NET Framework 3.5 and earlier versions, the AM/PM designator is ignored. diff --git a/xml/System/DateTimeOffset.xml b/xml/System/DateTimeOffset.xml index 8034c0604b0..15da02ce5d7 100644 --- a/xml/System/DateTimeOffset.xml +++ b/xml/System/DateTimeOffset.xml @@ -406,7 +406,7 @@ -or- - s less than -14 hours or greater than 14 hours. + is less than -14 hours or greater than 14 hours. Instantiating a DateTimeOffset Object @@ -2593,11 +2593,11 @@ In .NET 6 and earlier versions, the `seconds` parameter is rounded to the neares ]]> - is less than zero. + is less than zero. -or- - is greater than . + is greater than . @@ -6354,7 +6354,7 @@ Me.ToUtcDateTime().ToFileTime() A format string. An object that supplies culture-specific formatting information. Converts the value of the current object to its equivalent string representation using the specified format and culture-specific format information. - A string representation of the value of the current object, as specified by and . + A string representation of the value of the current object, as specified by and . An array that defines the expected formats of . An object that supplies culture-specific formatting information about . A bitwise combination of enumeration values that indicates the permitted format of input. A typical value to specify is . - When the method returns, contains the equivalent to the date and time of , if the conversion succeeded, or DateTimeOffset.MinValue, if the conversion failed. The conversion fails if the does not contain a valid string representation of a date and time, or does not contain the date and time in the expected format defined by , or if is . This parameter is passed uninitialized. + When the method returns, contains the equivalent to the date and time of , if the conversion succeeded, or DateTimeOffset.MinValue, if the conversion failed. The conversion fails if the does not contain a valid string representation of a date and time, or does not contain the date and time in the expected format defined by , or if is . This parameter is passed uninitialized. Converts the specified string representation of a date and time to its equivalent using the specified array of formats, culture-specific format information, and style. The format of the string representation must match one of the specified formats exactly. if the parameter is successfully converted; otherwise, . diff --git a/xml/System/Decimal.xml b/xml/System/Decimal.xml index 55d86ba5838..6013a251811 100644 --- a/xml/System/Decimal.xml +++ b/xml/System/Decimal.xml @@ -1870,7 +1870,7 @@ ]]> - Compiler overload resolution may account for an apparent difference in the behavior of the two method overloads. If an implicit conversion between the argument and a is defined and the argument is not typed as an , compilers may perform an implicit conversion and call the method. Otherwise, they call the method, which always returns if its argument is not a value. The following example illustrates the difference in behavior between the two method overloads. In the case of all primitive integral types, including both signed and unsigned types, the first comparison returns because the compiler automatically performs a widening conversion and calls the method, whereas the second comparison returns because the compiler calls the method. + Compiler overload resolution may account for an apparent difference in the behavior of the two method overloads. If an implicit conversion between the argument and a is defined and the argument is not typed as an , compilers may perform an implicit conversion and call the method. Otherwise, they call the method, which always returns if its argument is not a value. The following example illustrates the difference in behavior between the two method overloads. In the case of all primitive integral types, including both signed and unsigned types, the first comparison returns because the compiler automatically performs a widening conversion and calls the method, whereas the second comparison returns because the compiler calls the method. :::code language="csharp" source="~/snippets/csharp/System/Decimal/Equals/equalsoverl.cs" interactive="try-dotnet" id="Snippet2"::: :::code language="fsharp" source="~/snippets/fsharp/System/Decimal/Equals/equalsoverl.fs" id="Snippet2"::: @@ -1959,7 +1959,7 @@ ]]> - Compiler overload resolution may account for an apparent difference in the behavior of the two method overloads. If an implicit conversion between the argument and a is defined and the argument is not typed as an , compilers may perform an implicit conversion and call the method. Otherwise, they call the method, which always returns if its argument is not a value. The following example illustrates the difference in behavior between the two method overloads. In the case of all primitive integral types, including both signed and unsigned types, the first comparison returns because the compiler automatically performs a widening conversion and calls the method, whereas the second comparison returns because the compiler calls the method. + Compiler overload resolution may account for an apparent difference in the behavior of the two method overloads. If an implicit conversion between the argument and a is defined and the argument is not typed as an , compilers may perform an implicit conversion and call the method. Otherwise, they call the method, which always returns if its argument is not a value. The following example illustrates the difference in behavior between the two method overloads. In the case of all primitive integral types, including both signed and unsigned types, the first comparison returns because the compiler automatically performs a widening conversion and calls the method, whereas the second comparison returns because the compiler calls the method. :::code language="csharp" source="~/snippets/csharp/System/Decimal/Equals/equalsoverl.cs" interactive="try-dotnet" id="Snippet2"::: :::code language="fsharp" source="~/snippets/fsharp/System/Decimal/Equals/equalsoverl.fs" id="Snippet2"::: @@ -11323,8 +11323,8 @@ This member is an explicit interface member implementation. It can be used only A span containing the characters representing the number to convert. - When this method returns, contains the number that is equivalent to the numeric value contained in , if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or , is not a number in a format compliant with , or represents a number less than Decimal.MinValue or greater than Decimal.MaxValue. This parameter is passed uininitialized; any value originally supplied in is overwritten. - Converts the span representation of a number to its equivalent using the specified style and culture-specific format. A return value indicates whether the conversion succeeded or failed. + When this method returns, contains the number that is equivalent to the numeric value contained in , if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or or represents a number less than Decimal.MinValue or greater than Decimal.MaxValue. This parameter is passed uininitialized; any value originally supplied in is overwritten. + Converts the span representation of a number to its equivalent using the culture-specific format. A return value indicates whether the conversion succeeded or failed. if was converted successfully; otherwise, . To be added. diff --git a/xml/System/Delegate.xml b/xml/System/Delegate.xml index 6e8225b1861..1bee377ba17 100644 --- a/xml/System/Delegate.xml +++ b/xml/System/Delegate.xml @@ -1123,11 +1123,7 @@ For examples, see [Supplemental API remarks for System.Delegate.CreateDelegate]( -or- - is not a method ( method in Visual Basic). - - -or- - - cannot be bound, for example because it cannot be found, and is . + is not a method ( method in Visual Basic). The method of is not found. The caller does not have the permissions necessary to access . @@ -2636,7 +2632,7 @@ The number, order, or type of parameters listed in is i The delegate that supplies the invocation list to remove from the invocation list of the current delegate. Removes the invocation list of a delegate from the invocation list of another delegate. - A new delegate with an invocation list formed by taking the invocation list of the current delegate and removing the invocation list of , if the invocation list of is found within the current delegate's invocation list. Returns the current delegate if is or if the invocation list of is not found within the current delegate's invocation list. Returns if the invocation list of is equal to the current delegate's invocation list. + A new delegate with an invocation list formed by taking the invocation list of the current delegate and removing the invocation list of , if the invocation list of is found within the current delegate's invocation list. Returns the current delegate if is or if the invocation list of is not found within the current delegate's invocation list. Returns if the invocation list of is equal to the current delegate's invocation list. A character span that contains the string representation of the number to convert. - When this method returns, contains the double-precision floating-point number equivalent of the numeric value or symbol contained in parameter, if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or empty, or is not in a format compliant with . The conversion also fails if is not a valid combination of enumerated constants. If is a valid number less than Double.MinValue, is . If is a valid number greater than Double.MaxValue, is . This parameter is passed uninitialized; any value originally supplied in will be overwritten. + When this method returns, contains the double-precision floating-point number equivalent of the numeric value or symbol contained in parameter, if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or empty. If is a valid number less than Double.MinValue, is . If is a valid number greater than Double.MaxValue, is . This parameter is passed uninitialized; any value originally supplied in will be overwritten. Converts the span representation of a number in a specified style and culture-specific format to its double-precision floating-point number equivalent. A return value indicates whether the conversion succeeded or failed. if was converted successfully; otherwise, . diff --git a/xml/System/Enum.xml b/xml/System/Enum.xml index f6c1a16c478..adf161f0db8 100644 --- a/xml/System/Enum.xml +++ b/xml/System/Enum.xml @@ -1792,7 +1792,7 @@ An enumeration type. A string containing the name or value to convert. Converts the string representation of the name or numeric value of one or more enumerated constants specified by to an equivalent enumerated object. - An object of type whose value is represented by . + An object of type whose value is represented by . To be added. is not an type. @@ -1923,7 +1923,7 @@ to ignore case; to regard case. Converts the string representation of the name or numeric value of one or more enumerated constants specified by to an equivalent enumerated object. A parameter specifies whether the operation is case-insensitive. - An object of type whose value is represented by . + An object of type whose value is represented by . To be added. is not an type. @@ -4484,7 +4484,7 @@ If the parse operation fails, the `result` parameter contains the default value ]]> - is not an enumeration type. + is not an enumeration type. .NET 8 and later versions: is a Boolean-backed enumeration type. @@ -4652,7 +4652,7 @@ If the parse operation fails, the `result` parameter contains the default value ]]> - is not an enumeration type. + is not an enumeration type. .NET 8 and later versions: is a Boolean-backed enumeration type. diff --git a/xml/System/Environment.xml b/xml/System/Environment.xml index 33f90eb2d9f..1e8617291c5 100644 --- a/xml/System/Environment.xml +++ b/xml/System/Environment.xml @@ -1321,7 +1321,7 @@ The following example creates environment variables for the is not a member of . + is not a member of . The current platform is not supported. GetFolderPath behavior on Unix diff --git a/xml/System/Guid.xml b/xml/System/Guid.xml index fa86c0db00d..7c917b510dd 100644 --- a/xml/System/Guid.xml +++ b/xml/System/Guid.xml @@ -2445,7 +2445,7 @@ Because the `provider` parameter is ignored, you cannot use it to provide a cust The span in which to write the GUID as a span of characters. When this method returns, contains the number of characters written into the span. - A read-only span containing the character representing one of the following specifiers that indicates the exact format to use when interpreting : "N", "D", "B", "P", or "X". + A read-only span containing the character representing one of the following specifiers that indicates the exact format to use when interpreting the current GUID instance: "N", "D", "B", "P", or "X". Tries to format the current GUID instance into the provided character span. if the formatting operation was successful; otherwise. diff --git a/xml/System/IComparable.xml b/xml/System/IComparable.xml index 9755f16dc40..e542ad981ce 100644 --- a/xml/System/IComparable.xml +++ b/xml/System/IComparable.xml @@ -56,30 +56,30 @@ Defines a generalized type-specific comparison method that a value type or class implements to order or sort its instances. - , that indicates whether the position of the current instance in the sort order is before, after, or the same as a second object of the same type. The instance's implementation is called automatically by methods such as and . - - The implementation of the method must return an that has one of three values, as shown in the following table. - -|Value|Meaning| -|-----------|-------------| -|Less than zero|The current instance precedes the object specified by the method in the sort order.| -|Zero|This current instance occurs in the same position in the sort order as the object specified by the method.| -|Greater than zero|This current instance follows the object specified by the method in the sort order.| - - All numeric types (such as and ) implement , as do , , and . Custom types should also provide their own implementation of to enable object instances to be ordered or sorted. - - - -## Examples - The following example illustrates the implementation of and the requisite method. - - :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/IComparable Example/CPP/source.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System/IComparable/Overview/source.cs" interactive="try-dotnet" id="Snippet1"::: - :::code language="fsharp" source="~/snippets/fsharp/System/IComparable/Overview/source.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/IComparable Example/VB/source.vb" id="Snippet1"::: + , that indicates whether the position of the current instance in the sort order is before, after, or the same as a second object of the same type. The instance's implementation is called automatically by methods such as and . + + The implementation of the method must return an that has one of three values, as shown in the following table. + +|Value|Meaning| +|-----------|-------------| +|Less than zero|The current instance precedes the object specified by the method in the sort order.| +|Zero|This current instance occurs in the same position in the sort order as the object specified by the method.| +|Greater than zero|This current instance follows the object specified by the method in the sort order.| + + All numeric types (such as and ) implement , as do , , and . Custom types should also provide their own implementation of to enable object instances to be ordered or sorted. + + + +## Examples + The following example illustrates the implementation of and the requisite method. + + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/IComparable Example/CPP/source.cpp" id="Snippet1"::: + :::code language="csharp" source="~/snippets/csharp/System/IComparable/Overview/source.cs" interactive="try-dotnet" id="Snippet1"::: + :::code language="fsharp" source="~/snippets/fsharp/System/IComparable/Overview/source.fs" id="Snippet1"::: + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/IComparable Example/VB/source.vb" id="Snippet1"::: ]]> @@ -130,63 +130,63 @@ An object to compare with this instance. Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. - A value that indicates the relative order of the objects being compared. The return value has these meanings: - - Value - - Meaning - - Less than zero - - This instance precedes in the sort order. - - Zero - - This instance occurs in the same position in the sort order as . - - Greater than zero - - This instance follows in the sort order. - + A value that indicates the relative order of the objects being compared. The return value has these meanings: + + Value + + Meaning + + Less than zero + + This instance precedes in the sort order. + + Zero + + This instance occurs in the same position in the sort order as . + + Greater than zero + + This instance follows in the sort order. + - method is implemented by types whose values can be ordered or sorted. It is called automatically by methods of non-generic collection objects, such as , to order each member of the array. If a custom class or structure does not implement , its members cannot be ordered and the sort operation can throw an . - - This method is only a definition and must be implemented by a specific class or value type to have effect. The meaning of the comparisons specified in the Return Value section ("precedes", "occurs in the same position as", and "follows") depends on the particular implementation. - - By definition, any object compares greater than (or follows) `null`, and two null references compare equal to each other. - - The parameter, `obj`, must be the same type as the class or value type that implements this interface; otherwise, an is thrown. - - - -## Examples - The following example illustrates the use of to compare a `Temperature` object implementing with another object. The `Temperature` object implements by simply wrapping a call to the method. - - :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/IComparable Example/CPP/source.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System/IComparable/Overview/source.cs" interactive="try-dotnet" id="Snippet1"::: - :::code language="fsharp" source="~/snippets/fsharp/System/IComparable/Overview/source.fs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/IComparable Example/VB/source.vb" id="Snippet1"::: + method is implemented by types whose values can be ordered or sorted. It is called automatically by methods of non-generic collection objects, such as , to order each member of the array. If a custom class or structure does not implement , its members cannot be ordered and the sort operation can throw an . + + This method is only a definition and must be implemented by a specific class or value type to have effect. The meaning of the comparisons specified in the Return Value section ("precedes", "occurs in the same position as", and "follows") depends on the particular implementation. + + By definition, any object compares greater than (or follows) `null`, and two null references compare equal to each other. + + The parameter, `obj`, must be the same type as the class or value type that implements this interface; otherwise, an is thrown. + + + +## Examples + The following example illustrates the use of to compare a `Temperature` object implementing with another object. The `Temperature` object implements by simply wrapping a call to the method. + + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_CLR/IComparable Example/CPP/source.cpp" id="Snippet1"::: + :::code language="csharp" source="~/snippets/csharp/System/IComparable/Overview/source.cs" interactive="try-dotnet" id="Snippet1"::: + :::code language="fsharp" source="~/snippets/fsharp/System/IComparable/Overview/source.fs" id="Snippet1"::: + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR/IComparable Example/VB/source.vb" id="Snippet1"::: ]]> is not the same type as this instance. - For objects A, B and C, the following must be true: - - A.CompareTo(A) must return zero. - - If A.CompareTo(B) returns zero, then B.CompareTo(A) must return zero. - - If A.CompareTo(B) returns zero and B.CompareTo(C) returns zero, then A.CompareTo(C) must return zero. - - If A.CompareTo(B) returns a value other than zero, then B.CompareTo(A) must return a value of the opposite sign. - - If A.CompareTo(B) returns a value not equal to zero, and B.CompareTo(C) returns a value of the same sign as , then A.CompareTo(C) must return a value of the same sign as and . + For objects A, B and C, the following must be true: + + A.CompareTo(A) must return zero. + + If A.CompareTo(B) returns zero, then B.CompareTo(A) must return zero. + + If A.CompareTo(B) returns zero and B.CompareTo(C) returns zero, then A.CompareTo(C) must return zero. + + If A.CompareTo(B) returns a value other than zero, then B.CompareTo(A) must return a value of the opposite sign. + + If A.CompareTo(B) returns a value "x" not equal to zero, and B.CompareTo(C) returns a value "y" of the same sign as "x", then A.CompareTo(C) must return a value of the same sign as "x" and "y". Use the method to determine the ordering of instances of a class. diff --git a/xml/System/Int16.xml b/xml/System/Int16.xml index 14e71591d50..efbafebb674 100644 --- a/xml/System/Int16.xml +++ b/xml/System/Int16.xml @@ -6661,8 +6661,8 @@ This member is an explicit interface member implementation. It can be used only A span containing the characters that represent the number to convert. - When this method returns, contains the 16-bit signed integer value equivalent to the number contained in , if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or , is not in a format compliant with , or represents a number less than Int16.MinValue or greater than Int16.MaxValue. This parameter is passed uninitialized; any value originally supplied in will be overwritten. - Converts the span representation of a number in a specified style and culture-specific format to its 16-bit signed integer equivalent. A return value indicates whether the conversion succeeded or failed. + When this method returns, contains the 16-bit signed integer value equivalent to the number contained in , if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or or represents a number less than Int16.MinValue or greater than Int16.MaxValue. This parameter is passed uninitialized; any value originally supplied in will be overwritten. + Converts the span representation of a number in a culture-specific format to its 16-bit signed integer equivalent. A return value indicates whether the conversion succeeded or failed. if was converted successfully; otherwise, . To be added. diff --git a/xml/System/Int32.xml b/xml/System/Int32.xml index cec131b8a2a..6c1e4a2730a 100644 --- a/xml/System/Int32.xml +++ b/xml/System/Int32.xml @@ -6765,8 +6765,8 @@ This member is an explicit interface member implementation. It can be used only A span containing the characters that represent the number to convert. - When this method returns, contains the 32-bit signed integer value equivalent of the number contained in , if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or , is not in a format compliant with , or represents a number less than Int32.MinValue or greater than Int32.MaxValue. This parameter is passed uninitialized; any value originally supplied in will be overwritten. - Converts the span representation of a number in a specified style and culture-specific format to its 32-bit signed integer equivalent. A return value indicates whether the conversion succeeded. + When this method returns, contains the 32-bit signed integer value equivalent of the number contained in , if the conversion succeeded, or zero if the conversion failed. The conversion fails if the parameter is or or represents a number less than Int32.MinValue or greater than Int32.MaxValue. This parameter is passed uninitialized; any value originally supplied in will be overwritten. + Converts the span representation of a number in a culture-specific format to its 32-bit signed integer equivalent. A return value indicates whether the conversion succeeded. if was converted successfully; otherwise, . To be added. diff --git a/xml/System/IntPtr.xml b/xml/System/IntPtr.xml index d8696d7f572..5f4da8ab974 100644 --- a/xml/System/IntPtr.xml +++ b/xml/System/IntPtr.xml @@ -1606,8 +1606,7 @@ For this method matches the IEE Gets the largest possible value of . - - if it is greater than ; otherwise, . + The largest possible value of . To be added. @@ -1738,8 +1737,7 @@ For this method matches the IEE Gets the smallest possible value of . - - if it is less than ; otherwise, . + The smallest possible value of . To be added. diff --git a/xml/System/Lazy`1.xml b/xml/System/Lazy`1.xml index 092c6c9fd84..a4bb19e52cd 100644 --- a/xml/System/Lazy`1.xml +++ b/xml/System/Lazy`1.xml @@ -93,95 +93,95 @@ The type of object that is being lazily initialized. Provides support for lazy initialization. - . The type argument of the object that you create specifies the type of the object that you want to initialize lazily. The constructor that you use to create the object determines the characteristics of the initialization. Lazy initialization occurs the first time the property is accessed. - - In most cases, choosing a constructor depends on your answers to two questions: - -- Will the lazily initialized object be accessed from more than one thread? If so, the object might create it on any thread. You can use one of the simple constructors whose default behavior is to create a thread-safe object, so that only one instance of the lazily instantiated object is created no matter how many threads try to access it. To create a object that is not thread safe, you must use a constructor that enables you to specify no thread safety. - + . The type argument of the object that you create specifies the type of the object that you want to initialize lazily. The constructor that you use to create the object determines the characteristics of the initialization. Lazy initialization occurs the first time the property is accessed. + + In most cases, choosing a constructor depends on your answers to two questions: + +- Will the lazily initialized object be accessed from more than one thread? If so, the object might create it on any thread. You can use one of the simple constructors whose default behavior is to create a thread-safe object, so that only one instance of the lazily instantiated object is created no matter how many threads try to access it. To create a object that is not thread safe, you must use a constructor that enables you to specify no thread safety. + > [!CAUTION] - > Making the object thread safe does not protect the lazily initialized object. If multiple threads can access the lazily initialized object, you must make its properties and methods safe for multithreaded access. - -- Does lazy initialization require a lot of code, or does the lazily initialized object have a parameterless constructor that does everything you need and doesn't throw exceptions? If you need to write initialization code or if exceptions need to be handled, use one of the constructors that takes a factory method. Write your initialization code in the factory method. - - The following table shows which constructor to choose, based on these two factors: - -|Object will be accessed by|If no initialization code is required (parameterless constructor), use|If initialization code is required, use| -|--------------------------------|------------------------------------------------------------------------|---------------------------------------------| -|Multiple threads||| -|One thread| with `isThreadSafe` set to `false`.| with `isThreadSafe` set to `false`.| - - You can use a lambda expression to specify the factory method. This keeps all the initialization code in one place. The lambda expression captures the context, including any arguments you pass to the lazily initialized object's constructor. - - **Exception caching** When you use factory methods, exceptions are cached. That is, if the factory method throws an exception the first time a thread tries to access the property of the object, the same exception is thrown on every subsequent attempt. This ensures that every call to the property produces the same result and avoids subtle errors that might arise if different threads get different results. The stands in for an actual `T` that otherwise would have been initialized at some earlier point, usually during startup. A failure at that earlier point is usually fatal. If there is a potential for a recoverable failure, we recommend that you build the retry logic into the initialization routine (in this case, the factory method), just as you would if you weren't using lazy initialization. - - **Alternative to locking** In certain situations, you might want to avoid the overhead of the object's default locking behavior. In rare situations, there might be a potential for deadlocks. In such cases, you can use the or constructor, and specify . This enables the object to create a copy of the lazily initialized object on each of several threads if the threads call the property simultaneously. The object ensures that all threads use the same instance of the lazily initialized object and discards the instances that are not used. Thus, the cost of reducing the locking overhead is that your program might sometimes create and discard extra copies of an expensive object. In most cases, this is unlikely. The examples for the and constructors demonstrate this behavior. - + > Making the object thread safe does not protect the lazily initialized object. If multiple threads can access the lazily initialized object, you must make its properties and methods safe for multithreaded access. + +- Does lazy initialization require a lot of code, or does the lazily initialized object have a parameterless constructor that does everything you need and doesn't throw exceptions? If you need to write initialization code or if exceptions need to be handled, use one of the constructors that takes a factory method. Write your initialization code in the factory method. + + The following table shows which constructor to choose, based on these two factors: + +|Object will be accessed by|If no initialization code is required (parameterless constructor), use|If initialization code is required, use| +|--------------------------------|------------------------------------------------------------------------|---------------------------------------------| +|Multiple threads||| +|One thread| with `isThreadSafe` set to `false`.| with `isThreadSafe` set to `false`.| + + You can use a lambda expression to specify the factory method. This keeps all the initialization code in one place. The lambda expression captures the context, including any arguments you pass to the lazily initialized object's constructor. + + **Exception caching** When you use factory methods, exceptions are cached. That is, if the factory method throws an exception the first time a thread tries to access the property of the object, the same exception is thrown on every subsequent attempt. This ensures that every call to the property produces the same result and avoids subtle errors that might arise if different threads get different results. The stands in for an actual `T` that otherwise would have been initialized at some earlier point, usually during startup. A failure at that earlier point is usually fatal. If there is a potential for a recoverable failure, we recommend that you build the retry logic into the initialization routine (in this case, the factory method), just as you would if you weren't using lazy initialization. + + **Alternative to locking** In certain situations, you might want to avoid the overhead of the object's default locking behavior. In rare situations, there might be a potential for deadlocks. In such cases, you can use the or constructor, and specify . This enables the object to create a copy of the lazily initialized object on each of several threads if the threads call the property simultaneously. The object ensures that all threads use the same instance of the lazily initialized object and discards the instances that are not used. Thus, the cost of reducing the locking overhead is that your program might sometimes create and discard extra copies of an expensive object. In most cases, this is unlikely. The examples for the and constructors demonstrate this behavior. + > [!IMPORTANT] -> When you specify , exceptions are never cached, even if you specify a factory method. - - **Equivalent constructors** In addition to enabling the use of , the and constructors can duplicate the functionality of the other constructors. The following table shows the parameter values that produce equivalent behavior. - -|To create a object that is|For constructors that have a `LazyThreadSafetyMode` `mode` parameter, set `mode` to|For constructors that have a Boolean `isThreadSafe` parameter, set `isThreadSafe` to|For constructors with no thread safety parameters| -|-------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------|-------------------------------------------------------| -|Fully thread safe; uses locking to ensure that only one thread initializes the value.||`true`|All such constructors are fully thread safe.| -|Not thread safe.||`false`|Not applicable.| -|Fully thread safe; threads race to initialize the value.||Not applicable.|Not applicable.| - - **Other capabilities** For information about the use of with thread-static fields, or as the backing store for properties, see [Lazy Initialization](/dotnet/framework/performance/lazy-initialization). - - - -## Examples - The following example demonstrates the use of the class to provide lazy initialization with access from multiple threads. - +> When you specify , exceptions are never cached, even if you specify a factory method. + + **Equivalent constructors** In addition to enabling the use of , the and constructors can duplicate the functionality of the other constructors. The following table shows the parameter values that produce equivalent behavior. + +|To create a object that is|For constructors that have a `LazyThreadSafetyMode` `mode` parameter, set `mode` to|For constructors that have a Boolean `isThreadSafe` parameter, set `isThreadSafe` to|For constructors with no thread safety parameters| +|-------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------|-------------------------------------------------------| +|Fully thread safe; uses locking to ensure that only one thread initializes the value.||`true`|All such constructors are fully thread safe.| +|Not thread safe.||`false`|Not applicable.| +|Fully thread safe; threads race to initialize the value.||Not applicable.|Not applicable.| + + **Other capabilities** For information about the use of with thread-static fields, or as the backing store for properties, see [Lazy Initialization](/dotnet/framework/performance/lazy-initialization). + + + +## Examples + The following example demonstrates the use of the class to provide lazy initialization with access from multiple threads. + > [!NOTE] -> The example uses the constructor. It also demonstrates the use of the constructor (specifying `true` for `isThreadSafe`) and the constructor (specifying for `mode`). To switch to a different constructor, just change which constructors are commented out. -> -> For an example that demonstrates exception caching using the same constructors, see the constructor. - - The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The four key sections of code illustrate the creation of the initializer, the factory method, the actual initialization, and the constructor of the `LargeObject` class, which displays a message when the object is created. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: - +> The example uses the constructor. It also demonstrates the use of the constructor (specifying `true` for `isThreadSafe`) and the constructor (specifying for `mode`). To switch to a different constructor, just change which constructors are commented out. +> +> For an example that demonstrates exception caching using the same constructors, see the constructor. + + The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The four key sections of code illustrate the creation of the initializer, the factory method, the actual initialization, and the constructor of the `LargeObject` class, which displays a message when the object is created. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/Overview/example.cs" id="Snippetnewlazy"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/Overview/example.fs" id="Snippetnewlazy"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetnewlazy"::: - - The factory method shows the creation of the object, with a placeholder for further initialization: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetnewlazy"::: + + The factory method shows the creation of the object, with a placeholder for further initialization: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/Overview/example.cs" id="Snippetfactoryfunc"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/Overview/example.fs" id="Snippetfactoryfunc"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetfactoryfunc"::: - - Note that the first two code sections could be combined by using a lambda function, as shown here: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetfactoryfunc"::: + + Note that the first two code sections could be combined by using a lambda function, as shown here: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/Overview/lambda.cs" id="Snippetinitwithlambda"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/Overview/lambda.fs" id="Snippetinitwithlambda"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/lambda.vb" id="Snippetinitwithlambda"::: - - The example pauses, to indicate that an indeterminate period may elapse before lazy initialization occurs. When you press the **Enter** key, the example creates and starts three threads. The `ThreadProc` method that's used by all three threads calls the property. The first time this happens, the `LargeObject` instance is created: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/lambda.vb" id="Snippetinitwithlambda"::: + + The example pauses, to indicate that an indeterminate period may elapse before lazy initialization occurs. When you press the **Enter** key, the example creates and starts three threads. The `ThreadProc` method that's used by all three threads calls the property. The first time this happens, the `LargeObject` instance is created: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/Overview/example.cs" id="Snippetvalueprop"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/Overview/example.fs" id="Snippetvalueprop"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetvalueprop"::: - - The constructor of the `LargeObject` class, which includes the last key section of code, displays a message and records the identity of the initializing thread. The output from the program appears at the end of the full code listing. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetvalueprop"::: + + The constructor of the `LargeObject` class, which includes the last key section of code, displays a message and records the identity of the initializing thread. The output from the program appears at the end of the full code listing. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/Overview/example.cs" id="Snippetlargector"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/Overview/example.fs" id="Snippetlargector"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetlargector"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetlargector"::: + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/Overview/example.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/Overview/example.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1/vb/example.vb" id="Snippetall"::: + ]]> By default, all public and protected members of the class are thread safe and may be used concurrently from multiple threads. These thread-safety guarantees may be removed optionally and per instance, using parameters to the type's constructors. @@ -242,41 +242,41 @@ Initializes a new instance of the class. When lazy initialization occurs, the parameterless constructor of the target type is used. - instance that is initialized with this constructor is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. - - A instance that is created with this constructor does not cache exceptions. For more information, see the class or the enumeration. - - - -## Examples - The following example demonstrates the use of this constructor. It also illustrates the use of the constructor (specifying `true` for `isThreadSafe`) and the constructor (specifying for `mode`). To switch to a different constructor, just change which constructors are commented out. - - The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The two key lines of code in this example are the creation of the initializer and the actual initialization. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: - + instance that is initialized with this constructor is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. + + A instance that is created with this constructor does not cache exceptions. For more information, see the class or the enumeration. + + + +## Examples + The following example demonstrates the use of this constructor. It also illustrates the use of the constructor (specifying `true` for `isThreadSafe`) and the constructor (specifying for `mode`). To switch to a different constructor, just change which constructors are commented out. + + The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The two key lines of code in this example are the creation of the initializer and the actual initialization. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example.cs" id="Snippetnewlazy"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example.fs" id="Snippetnewlazy"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctor/vb/example.vb" id="Snippetnewlazy"::: - - The example creates and starts three threads that block on a object, so that the example can release the threads all at once. The `ThreadProc` method that's used by all three threads calls the property to get the `LargeObject` instance: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctor/vb/example.vb" id="Snippetnewlazy"::: + + The example creates and starts three threads that block on a object, so that the example can release the threads all at once. The `ThreadProc` method that's used by all three threads calls the property to get the `LargeObject` instance: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example.cs" id="Snippetvalueprop"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example.fs" id="Snippetvalueprop"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctor/vb/example.vb" id="Snippetvalueprop"::: - - The class provides locking, so that only one thread is allowed to create the `LargeObject` instance. The example demonstrates that the other threads all get the same instance. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctor/vb/example.vb" id="Snippetvalueprop"::: + + The class provides locking, so that only one thread is allowed to create the `LargeObject` instance. The example demonstrates that the other threads all get the same instance. + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctor/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctor/vb/example.vb" id="Snippetall"::: + ]]> Lazy Initialization @@ -326,30 +326,30 @@ to make this instance usable concurrently by multiple threads; to make the instance usable by only one thread at a time. Initializes a new instance of the class. When lazy initialization occurs, the parameterless constructor of the target type and the specified initialization mode are used. - instance that is initialized with this constructor is if `isThreadSafe` is `true`; otherwise, the mode is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. To specify the mode, use the or constructor. - - A instance that is created with this constructor does not cache exceptions. For more information, see the class or the enumeration. - - - -## Examples - The following example demonstrates the use of this constructor to create a lazy initializer that is not thread safe, for scenarios where all access to the lazily initialized object occurs on the same thread. It also demonstrates the use of the constructor (specifying for `mode`. To switch to a different constructor, just change which constructor is commented out. - + instance that is initialized with this constructor is if `isThreadSafe` is `true`; otherwise, the mode is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. To specify the mode, use the or constructor. + + A instance that is created with this constructor does not cache exceptions. For more information, see the class or the enumeration. + + + +## Examples + The following example demonstrates the use of this constructor to create a lazy initializer that is not thread safe, for scenarios where all access to the lazily initialized object occurs on the same thread. It also demonstrates the use of the constructor (specifying for `mode`. To switch to a different constructor, just change which constructor is commented out. + > [!NOTE] -> For code that demonstrates how to use this constructor in multithreaded scenarios (specifying `true` for `isThreadSafe`), see the example for the constructor. - - The example defines a `LargeObject` class that will be initialized lazily. In the `Main` method, the example creates a instance and then pauses. When you press the **Enter** key, the example accesses the property of the instance, which causes initialization to occur. The constructor of the `LargeObject` class displays a console message. - +> For code that demonstrates how to use this constructor in multithreaded scenarios (specifying `true` for `isThreadSafe`), see the example for the constructor. + + The example defines a `LargeObject` class that will be initialized lazily. In the `Main` method, the example creates a instance and then pauses. When you press the **Enter** key, the example accesses the property of the instance, which causes initialization to occur. The constructor of the `LargeObject` class displays a console message. + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example1.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example1.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorbool/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorbool/vb/example.vb" id="Snippetall"::: + ]]> Lazy Initialization @@ -398,47 +398,47 @@ The delegate that is invoked to produce the lazily initialized value when it is needed. Initializes a new instance of the class. When lazy initialization occurs, the specified initialization function is used. - instance that is initialized with this constructor is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. - - Exceptions that are thrown by `valueFactory` are cached. For more information, see the class or the enumeration. - - - -## Examples - The following example demonstrates the use of this constructor to provide lazy initialization with exception caching. It also demonstrates the use of the constructor (specifying `true` for `isThreadSafe`) and the constructor (specifying for `mode`). To switch to a different constructor, just change which constructors are commented out. - - The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The three key sections of code illustrate the creation of the initializer, the actual initialization, and the constructor of the `LargeObject` class, which demonstrates exception caching. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: - + instance that is initialized with this constructor is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. + + Exceptions that are thrown by `valueFactory` are cached. For more information, see the class or the enumeration. + + + +## Examples + The following example demonstrates the use of this constructor to provide lazy initialization with exception caching. It also demonstrates the use of the constructor (specifying `true` for `isThreadSafe`) and the constructor (specifying for `mode`). To switch to a different constructor, just change which constructors are commented out. + + The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The three key sections of code illustrate the creation of the initializer, the actual initialization, and the constructor of the `LargeObject` class, which demonstrates exception caching. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example2.cs" id="Snippetnewlazy"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example2.fs" id="Snippetnewlazy"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetnewlazy"::: - - The example creates and starts three threads. The `ThreadProc` method that's used by all three threads calls the property to get the `LargeObject` instance: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetnewlazy"::: + + The example creates and starts three threads. The `ThreadProc` method that's used by all three threads calls the property to get the `LargeObject` instance: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example2.cs" id="Snippetvalueprop"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example2.fs" id="Snippetvalueprop"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetvalueprop"::: - - In the constructor of the `LargeObject` class, the third key section of code throws an exception the first time a `LargeObject` instance is created, but thereafter allows instance creation to occur: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetvalueprop"::: + + In the constructor of the `LargeObject` class, the third key section of code throws an exception the first time a `LargeObject` instance is created, but thereafter allows instance creation to occur: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example2.cs" id="Snippetlargector"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example2.fs" id="Snippetlargector"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetlargector"::: - - When the example is run, the first thread that tries to create an instance of `LargeObject` fails, and the exception is caught. You might expect that the next thread would successfully create an instance, but the object has cached the exception. Because of this, all three threads throw the exception. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetlargector"::: + + When the example is run, the first thread that tries to create an instance of `LargeObject` fails, and the exception is caught. You might expect that the next thread would successfully create an instance, but the object has cached the exception. Because of this, all three threads throw the exception. + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example2.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example2.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfunc/vb/example.vb" id="Snippetall"::: + ]]> @@ -487,50 +487,50 @@ One of the enumeration values that specifies the thread safety mode. - Initializes a new instance of the class that uses the parameterless constructor of and the specified thread-safety mode. + Initializes a new instance of the class that uses the parameterless constructor of and the specified thread-safety mode. - instance describes the behavior when multiple threads try to initialize the instance. - - A instance that is created with this constructor does not cache exceptions. For more information, see the class or the enumeration. - - - -## Examples - The following example demonstrates the use of this constructor to create a lazy initializer that enables multiple threads to race to create an object lazily. Multiple threads might succeed in creating instances, but all threads use the instance that was created first. - + instance describes the behavior when multiple threads try to initialize the instance. + + A instance that is created with this constructor does not cache exceptions. For more information, see the class or the enumeration. + + + +## Examples + The following example demonstrates the use of this constructor to create a lazy initializer that enables multiple threads to race to create an object lazily. Multiple threads might succeed in creating instances, but all threads use the instance that was created first. + > [!NOTE] -> For an example that demonstrates how to use this constructor in single-threaded scenarios (specifying for `mode`), see the constructor. For an example that demonstrates how to use this constructor to provide locking instead of race conditions in multithreaded scenarios (specifying for `mode`), see the constructor. - - The example defines a `LargeObject` class that will be initialized lazily by any of several threads. The three key sections of code illustrate the creation of the initializer, the actual initialization, and the constructor and finalizer of the `LargeObject` class. At the beginning of the `Main` method, the example creates the object that performs lazy initialization of the `LargeObject`: - +> For an example that demonstrates how to use this constructor in single-threaded scenarios (specifying for `mode`), see the constructor. For an example that demonstrates how to use this constructor to provide locking instead of race conditions in multithreaded scenarios (specifying for `mode`), see the constructor. + + The example defines a `LargeObject` class that will be initialized lazily by any of several threads. The three key sections of code illustrate the creation of the initializer, the actual initialization, and the constructor and finalizer of the `LargeObject` class. At the beginning of the `Main` method, the example creates the object that performs lazy initialization of the `LargeObject`: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example5.cs" id="Snippetnewlazy"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example5.fs" id="Snippetnewlazy"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetnewlazy"::: - - The example creates and starts three threads that block on a object, so that the example can release the threads all at once. In the `ThreadProc` method that's used by all three threads, calling the property creates the `LargeObject` instance: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetnewlazy"::: + + The example creates and starts three threads that block on a object, so that the example can release the threads all at once. In the `ThreadProc` method that's used by all three threads, calling the property creates the `LargeObject` instance: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example5.cs" id="Snippetvalueprop"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example5.fs" id="Snippetvalueprop"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetvalueprop"::: - - Because the constructor for the instance specified , all three threads are allowed to create `LargeObject` instances. The example demonstrates this by displaying console messages in the constructor and in the finalizer of the `LargeObject` class: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetvalueprop"::: + + Because the constructor for the instance specified , all three threads are allowed to create `LargeObject` instances. The example demonstrates this by displaying console messages in the constructor and in the finalizer of the `LargeObject` class: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example5.cs" id="Snippetctorfinalizer"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example5.fs" id="Snippetctorfinalizer"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetctorfinalizer"::: - - However, the object ensures that only one instance is used by all threads. The output from the example shows that all three threads use the same instance, and also shows that the other two instances can be reclaimed by garbage collection. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetctorfinalizer"::: + + However, the object ensures that only one instance is used by all threads. The output from the example shows that all three threads use the same instance, and also shows that the other two instances can be reclaimed by garbage collection. + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example5.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example5.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorltsm/vb/example.vb" id="Snippetall"::: + ]]> @@ -628,50 +628,50 @@ An instance created with this constructor is usable by multiple threads concurre to make this instance usable concurrently by multiple threads; to make this instance usable by only one thread at a time. Initializes a new instance of the class. When lazy initialization occurs, the specified initialization function and initialization mode are used. - instance that is initialized with this constructor is if `isThreadSafe` is `true`; otherwise, the mode is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. - - To specify the mode, use the or constructor. - - Exceptions that are thrown by `valueFactory` are cached. For more information, see the class or the enumeration. - - - -## Examples - The following example demonstrates the use of this constructor to provide lazy initialization with exception caching, in a scenario with a single thread. It also demonstrates the use of the constructor (specifying for `mode`). To switch to that constructor, just change which constructor is commented out. - + instance that is initialized with this constructor is if `isThreadSafe` is `true`; otherwise, the mode is . The thread safety mode describes the behavior when multiple threads try to initialize the instance. + + To specify the mode, use the or constructor. + + Exceptions that are thrown by `valueFactory` are cached. For more information, see the class or the enumeration. + + + +## Examples + The following example demonstrates the use of this constructor to provide lazy initialization with exception caching, in a scenario with a single thread. It also demonstrates the use of the constructor (specifying for `mode`). To switch to that constructor, just change which constructor is commented out. + > [!NOTE] -> For code that demonstrates how to use this constructor in multithreaded scenarios (specifying `true` for `isThreadSafe`), see the example for the constructor. - - The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The three key sections of code illustrate the creation of the initializer, the actual initialization, and the constructor of the `LargeObject` class, which demonstrates exception caching. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: - +> For code that demonstrates how to use this constructor in multithreaded scenarios (specifying `true` for `isThreadSafe`), see the example for the constructor. + + The example defines a `LargeObject` class that will be initialized lazily by one of several threads. The three key sections of code illustrate the creation of the initializer, the actual initialization, and the constructor of the `LargeObject` class, which demonstrates exception caching. At the beginning of the `Main` method, the example creates the thread-safe lazy initializer for `LargeObject`: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example3.cs" id="Snippetnewlazy"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example3.fs" id="Snippetnewlazy"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetnewlazy"::: - - In the call to the constructor, the `isThreadSafe` parameter is `false`, so the is not thread safe. Because it's not thread safe, the example calls the property three times on the same thread: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetnewlazy"::: + + In the call to the constructor, the `isThreadSafe` parameter is `false`, so the is not thread safe. Because it's not thread safe, the example calls the property three times on the same thread: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example3.cs" id="Snippetvalueprop"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example3.fs" id="Snippetvalueprop"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetvalueprop"::: - - In the constructor of the `LargeObject` class, the third key section of code throws an exception the first time a `LargeObject` instance is created, but thereafter allows instance creation to occur: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetvalueprop"::: + + In the constructor of the `LargeObject` class, the third key section of code throws an exception the first time a `LargeObject` instance is created, but thereafter allows instance creation to occur: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example3.cs" id="Snippetlargector"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example3.fs" id="Snippetlargector"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetlargector"::: - - When the example is run, the first attempt to create an instance of `LargeObject` fails, and the exception is caught. You might expect that the next attempt would succeed, but the object has cached the exception. Because of this, all three attempts throw the exception. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetlargector"::: + + When the example is run, the first attempt to create an instance of `LargeObject` fails, and the exception is caught. You might expect that the next attempt would succeed, but the object has cached the exception. Because of this, all three attempts throw the exception. + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example3.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example3.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncbool/vb/example.vb" id="Snippetall"::: + ]]> @@ -724,61 +724,61 @@ An instance created with this constructor is usable by multiple threads concurre One of the enumeration values that specifies the thread safety mode. Initializes a new instance of the class that uses the specified initialization function and thread-safety mode. - instance describes the behavior when multiple threads try to initialize the instance. - - Exceptions that are thrown by `valueFactory` are cached, unless `mode` is . For more information, see the class or the enumeration. - - - -## Examples - The following example demonstrates the use of this constructor to create a lazy initializer that enables multiple threads to race to create an object lazily. Multiple threads might succeed in creating instances, but all threads use the instance that was created first. In addition, the example demonstrates that exceptions are never cached when you specify , even if initialization is performed by a function instead of by the parameterless constructor of the lazily created type. - + instance describes the behavior when multiple threads try to initialize the instance. + + Exceptions that are thrown by `valueFactory` are cached, unless `mode` is . For more information, see the class or the enumeration. + + + +## Examples + The following example demonstrates the use of this constructor to create a lazy initializer that enables multiple threads to race to create an object lazily. Multiple threads might succeed in creating instances, but all threads use the instance that was created first. In addition, the example demonstrates that exceptions are never cached when you specify , even if initialization is performed by a function instead of by the parameterless constructor of the lazily created type. + > [!NOTE] -> For an example that demonstrates how to use this constructor in single-threaded scenarios (specifying for `mode`), see the constructor. For an example that demonstrates how to use this constructor to provide locking instead of race conditions in multithreaded scenarios (specifying for `mode`), see the constructor. - - The example defines a `LargeObject` class that will be initialized lazily by any of several threads. The four key sections of code illustrate the creation of the initializer, the actual initialization, the initialization function, and the constructor and finalizer of the `LargeObject` class. At the beginning of the `Main` method, the example creates the object that performs lazy initialization of the `LargeObject`: - +> For an example that demonstrates how to use this constructor in single-threaded scenarios (specifying for `mode`), see the constructor. For an example that demonstrates how to use this constructor to provide locking instead of race conditions in multithreaded scenarios (specifying for `mode`), see the constructor. + + The example defines a `LargeObject` class that will be initialized lazily by any of several threads. The four key sections of code illustrate the creation of the initializer, the actual initialization, the initialization function, and the constructor and finalizer of the `LargeObject` class. At the beginning of the `Main` method, the example creates the object that performs lazy initialization of the `LargeObject`: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example4.cs" id="Snippetnewlazy"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example4.fs" id="Snippetnewlazy"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetnewlazy"::: - - The lazy initializer uses a function to perform the initialization. In this case, a function is required because there is no parameterless constructor for the `LargeObject` class. - - The example creates and starts three threads that block on a object, so that the example can release the threads all at once. In the `ThreadProc` method that's used by all three threads, calling the property creates the `LargeObject` instance: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetnewlazy"::: + + The lazy initializer uses a function to perform the initialization. In this case, a function is required because there is no parameterless constructor for the `LargeObject` class. + + The example creates and starts three threads that block on a object, so that the example can release the threads all at once. In the `ThreadProc` method that's used by all three threads, calling the property creates the `LargeObject` instance: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example4.cs" id="Snippetvalueprop"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example4.fs" id="Snippetvalueprop"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetvalueprop"::: - - In the third key section of code, the lazy initialization function is called to create the `LargeObject` instance. The function throws an exception the first time it's called: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetvalueprop"::: + + In the third key section of code, the lazy initialization function is called to create the `LargeObject` instance. The function throws an exception the first time it's called: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example4.cs" id="Snippetfactoryfunc"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example4.fs" id="Snippetfactoryfunc"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetfactoryfunc"::: - - With any other setting, an unhandled exception in the initialization function would be cached. However, suppresses exception caching. The output from the example demonstrates that a subsequent attempt to initialize the object succeeds. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetfactoryfunc"::: + + With any other setting, an unhandled exception in the initialization function would be cached. However, suppresses exception caching. The output from the example demonstrates that a subsequent attempt to initialize the object succeeds. + > [!NOTE] -> The exception message usually appears after messages indicating that other threads have successfully initialized the object. This is because of the delay introduced by throwing and catching the exception. - - Because the constructor for the instance specified , all three threads are allowed to create `LargeObject` instances. The example demonstrates this by displaying console messages in the constructor and in the finalizer of the `LargeObject` class: - +> The exception message usually appears after messages indicating that other threads have successfully initialized the object. This is because of the delay introduced by throwing and catching the exception. + + Because the constructor for the instance specified , all three threads are allowed to create `LargeObject` instances. The example demonstrates this by displaying console messages in the constructor and in the finalizer of the `LargeObject` class: + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example4.cs" id="Snippetctorfinalizer"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example4.fs" id="Snippetctorfinalizer"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetctorfinalizer"::: - - The object ensures that only one instance is used by all threads (except the thread where the initialization function throws an exception). The output from the example shows this. - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetctorfinalizer"::: + + The object ensures that only one instance is used by all threads (except the thread where the initialization function throws an exception). The output from the example shows this. + > [!NOTE] -> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. - +> For simplicity, this example uses a global instance of , and all the methods are `static` (`Shared` in Visual Basic). These are not requirements for the use of lazy initialization. + :::code language="csharp" source="~/snippets/csharp/System/LazyT/.ctor/example4.cs" id="Snippetall"::: :::code language="fsharp" source="~/snippets/fsharp/System/LazyT/.ctor/example4.fs" id="Snippetall"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetall"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_CLR_System/system.lazy`1.ctorfuncltsm/vb/example.vb" id="Snippetall"::: + ]]> @@ -838,15 +838,15 @@ An instance created with this constructor is usable by multiple threads concurre if a value has been created for this instance; otherwise, . - instance, it may result in either a value being created or an exception being thrown. If an exception is thrown, subsequent behavior of the instance depends on whether exception caching is in effect. If the instance was created by using a constructor that does not specify an initialization function, then exception caching is not in effect. A subsequent attempt to initialize the might succeed, and after successful initialization the property returns `true`. If the instance was created with an initialization function (specified by the `valueFactory` parameter of the constructor), then exception caching is controlled by the thread safety mode. - -- If the mode is or , there is no second chance to initialize the instance. If an exception occurs and is unhandled in the initialization function, that exception is cached and rethrown on subsequent accesses of the property. No value is created if an exception is thrown, so in such cases returns `false`. - -- If the mode is , the first thread that succeeds in running the initialization function (or the parameterless constructor) creates the value for the instance. If the initialization function throws an exception on one thread, other threads can still try to initialize the instance. Until the value is created, the property returns `false`. - + instance, it may result in either a value being created or an exception being thrown. If an exception is thrown, subsequent behavior of the instance depends on whether exception caching is in effect. If the instance was created by using a constructor that does not specify an initialization function, then exception caching is not in effect. A subsequent attempt to initialize the might succeed, and after successful initialization the property returns `true`. If the instance was created with an initialization function (specified by the `valueFactory` parameter of the constructor), then exception caching is controlled by the thread safety mode. + +- If the mode is or , there is no second chance to initialize the instance. If an exception occurs and is unhandled in the initialization function, that exception is cached and rethrown on subsequent accesses of the property. No value is created if an exception is thrown, so in such cases returns `false`. + +- If the mode is , the first thread that succeeds in running the initialization function (or the parameterless constructor) creates the value for the instance. If the initialization function throws an exception on one thread, other threads can still try to initialize the instance. Until the value is created, the property returns `false`. + ]]> @@ -904,13 +904,13 @@ An instance created with this constructor is usable by multiple threads concurre Creates and returns a string representation of the property for this instance. The result of calling the method on the property for this instance, if the value has been created (that is, if the property returns ). Otherwise, a string indicating that the value has not been created. - property can be `null` after lazy initialization if the factory method that was specified for the `valueFactory` parameter of the , , or constructor returns `null`. - + property can be `null` after lazy initialization if the factory method that was specified for the `valueFactory` parameter of the , , or constructor returns `null`. + ]]> The property is . @@ -965,13 +965,13 @@ An instance created with this constructor is usable by multiple threads concurre Gets the lazily initialized value of the current instance. The lazily initialized value of the current instance. - property is `false`, accessing the property forces initialization. - - In addition to the exceptions that are listed, the property can throw any unhandled exception that is thrown by the factory method that was passed to the `valueFactory` parameter of the , , or constructor. - + property is `false`, accessing the property forces initialization. + + In addition to the exceptions that are listed, the property can throw any unhandled exception that is thrown by the factory method that was passed to the `valueFactory` parameter of the , , or constructor. + ]]> The instance is initialized to use the parameterless constructor of the type that is being lazily initialized, and permissions to access the constructor are missing. diff --git a/xml/System/Math.xml b/xml/System/Math.xml index a3dde7bba7b..27b2f23adb9 100644 --- a/xml/System/Math.xml +++ b/xml/System/Math.xml @@ -1569,7 +1569,7 @@ -or- - if equals . + if equals . Returns the logarithm of a specified number in a specified base. One of the values in the following table. (+Infinity denotes , -Infinity denotes , and NaN denotes .) - Return value + Return value > 0 - (0 << 1) -or-(> 1) + (0 << 1) -or-(> 1) lognewBase(a) @@ -1329,19 +1329,19 @@ Remainder = (MathF.Abs(dividend) - (MathF.Abs(divisor) * (any value) - < 0 + < 0 NaN != 1 - = 0 + = 0 NaN != 1 - = +Infinity + = +Infinity NaN @@ -1353,49 +1353,49 @@ Remainder = (MathF.Abs(dividend) - (MathF.Abs(divisor) * (any value) - = NaN + = NaN NaN (any value) - = 1 + = 1 NaN = 0 - 0 << 1 + 0 << 1 +Infinity = 0 - > 1 + > 1 -Infinity = +Infinity - 0 << 1 + 0 << 1 -Infinity = +Infinity - > 1 + > 1 +Infinity = 1 - = 0 + = 0 0 = 1 - = +Infinity + = +Infinity 0 diff --git a/xml/System/Memory`1.xml b/xml/System/Memory`1.xml index 6b99910d889..62b61594bdb 100644 --- a/xml/System/Memory`1.xml +++ b/xml/System/Memory`1.xml @@ -152,7 +152,7 @@ If `array` is `null`, this constructor returns a object ]]> - is a reference type, and is not an array of type . + is a reference type, and is not an array of type . -or- @@ -223,7 +223,7 @@ If `array` is `null`, this constructor returns a objec and exceeds the number of elements in the array. - is a reference type, and is not an array of type . + is a reference type, and is not an array of type . diff --git a/xml/System/ModuleHandle.xml b/xml/System/ModuleHandle.xml index 263ba58c4dc..1b1ef395e84 100644 --- a/xml/System/ModuleHandle.xml +++ b/xml/System/ModuleHandle.xml @@ -63,11 +63,11 @@ Represents a runtime handle for a module. - , , and methods provide efficient resolution of metadata tokens to runtime handles for fields, methods, and types in the current module. - + , , and methods provide efficient resolution of metadata tokens to runtime handles for fields, methods, and types in the current module. + ]]> @@ -465,13 +465,13 @@ Gets the metadata stream version. A 32-bit integer representing the metadata stream version. The high-order two bytes represent the major version number, and the low-order two bytes represent the minor version number. - [!NOTE] -> For more information on the metadata header, see the metadata specification in Partition II of [ECMA-335 Common Language Infrastructure (CLI)](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/). - +> For more information on the metadata header, see the metadata specification in Partition II of [ECMA-335 Common Language Infrastructure (CLI)](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/). + ]]> @@ -629,26 +629,26 @@ Returns a runtime handle for the field identified by the specified metadata token. A for the field identified by . - method overload, which allows you to supply the necessary context. - + method overload, which allows you to supply the necessary context. + > [!NOTE] > Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". - + ]]> - is not a valid token in the scope of the current module. - - -or- - - is not a token for a field in the scope of the current module. - - -or- - - identifies a field whose parent has a signature containing element type or . + is not a valid token in the scope of the current module. + + -or- + + is not a token for a field in the scope of the current module. + + -or- + + identifies a field whose parent has a signature containing element type or . The method is called on an empty field handle. @@ -704,25 +704,25 @@ Returns a runtime field handle for the field identified by the specified metadata token, specifying the generic type arguments of the type and method where the token is in scope. A for the field identified by . - [!NOTE] > Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". - + ]]> - is not a valid token in the scope of the current module. - - -or- - - is not a token for a field in the scope of the current module. - - -or- - - identifies a field whose parent has a signature containing element type or . + is not a valid token in the scope of the current module. + + -or- + + is not a token for a field in the scope of the current module. + + -or- + + identifies a field whose parent has a signature containing element type or . The method is called on an empty field handle. is not a valid token. @@ -785,26 +785,26 @@ Returns a runtime method handle for the method or constructor identified by the specified metadata token. A for the method or constructor identified by . - method overload, which allows you to supply the necessary context. - + method overload, which allows you to supply the necessary context. + > [!NOTE] -> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". - +> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". + ]]> - is not a valid metadata token for a method in the current module. - - -or- - - is not a token for a method or constructor in the scope of the current module. - - -or- - - is a whose signature contains element type or . + is not a valid metadata token for a method in the current module. + + -or- + + is not a token for a method or constructor in the scope of the current module. + + -or- + + is a whose signature contains element type or . The method is called on an empty method handle. @@ -864,25 +864,25 @@ Returns a runtime method handle for the method or constructor identified by the specified metadata token, specifying the generic type arguments of the type and method where the token is in scope. A for the method or constructor identified by . - [!NOTE] -> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". - +> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". + ]]> - is not a valid metadata token for a method in the current module. - - -or- - - is not a token for a method or constructor in the scope of the current module. - - -or- - - is a whose signature contains element type or . + is not a valid metadata token for a method in the current module. + + -or- + + is not a token for a method or constructor in the scope of the current module. + + -or- + + is a whose signature contains element type or . The method is called on an empty method handle. is not a valid token. @@ -945,26 +945,26 @@ Returns a runtime type handle for the type identified by the specified metadata token. A for the type identified by . - method overload, which allows you to supply the necessary context. - + method overload, which allows you to supply the necessary context. + > [!NOTE] -> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". - +> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". + ]]> - is not a valid metadata token for a type in the current module. - - -or- - - is not a token for a type in the scope of the current module. - - -or- - - is a whose signature contains element type or . + is not a valid metadata token for a type in the current module. + + -or- + + is not a token for a type in the scope of the current module. + + -or- + + is a whose signature contains element type or . The method is called on an empty type handle. @@ -1020,25 +1020,25 @@ Returns a runtime type handle for the type identified by the specified metadata token, specifying the generic type arguments of the type and method where the token is in scope. A for the type identified by . - [!NOTE] -> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". - +> Information about metadata tokens can be found in the [Common Language Infrastructure (CLI) documentation](https://www.ecma-international.org/publications-and-standards/standards/ecma-335/), especially "Partition II: Metadata Definition and Semantics". + ]]> - is not a valid metadata token for a type in the current module. - - -or- - - is not a token for a type in the scope of the current module. - - -or- - - is a whose signature contains element type or . + is not a valid metadata token for a type in the current module. + + -or- + + is not a token for a type in the scope of the current module. + + -or- + + is a whose signature contains element type or . The method is called on an empty type handle. is not a valid token. diff --git a/xml/System/ReadOnlySpan`1.xml b/xml/System/ReadOnlySpan`1.xml index a8dc0da6f36..f2b1a50af9d 100644 --- a/xml/System/ReadOnlySpan`1.xml +++ b/xml/System/ReadOnlySpan`1.xml @@ -233,7 +233,7 @@ A `ReadOnlySpan` instance is often used to reference the elements of an array ]]> - is a reference type or contains references and therefore cannot be stored in unmanaged memory. + is a reference type or contains references and therefore cannot be stored in unmanaged memory. is negative. @@ -643,7 +643,7 @@ This method returns `default` when `array` is `null`. Returns a read-only reference to an object of type T that can be used for pinning. - + This method is intended to support .NET compilers and is not intended to be called by user code. A reference to the element of the span at index 0, or if the span is empty. diff --git a/xml/System/Span`1.xml b/xml/System/Span`1.xml index 7a59fbb5dd7..6e40fbfa073 100644 --- a/xml/System/Span`1.xml +++ b/xml/System/Span`1.xml @@ -171,7 +171,7 @@ If `array` is `null`, this constructor returns a `null` `Span`. ]]> - is a reference type, and is not an array of type . + is a reference type, and is not an array of type . @@ -223,7 +223,7 @@ If `array` is `null`, this constructor returns a `null` `Span`. ]]> - is a reference type or contains pointers and therefore cannot be stored in unmanaged memory. + is a reference type or contains pointers and therefore cannot be stored in unmanaged memory. is negative. @@ -293,7 +293,7 @@ This method returns `default` when `array` is `null`. and exceeds the number of elements in the array. - is a reference type, and is not an array of type . + is a reference type, and is not an array of type . diff --git a/xml/System/String.xml b/xml/System/String.xml index 235c3857a2e..c3eed2639ef 100644 --- a/xml/System/String.xml +++ b/xml/System/String.xml @@ -1200,7 +1200,7 @@ The following example demonstrates that the - Character sets include ignorable characters. The method does not consider such characters when it performs a culture-sensitive comparison. For example, if the following code is run on the .NET Framework 4 or later, a culture-sensitive, case-insensitive comparison of "animal" with "Ani-mal" (using a soft hyphen, or U+00AD) indicates that the two strings are equivalent. + Character sets include ignorable characters. The method does not consider such characters when it performs a culture-sensitive comparison. For example, a culture-sensitive, case-insensitive comparison of "animal" with "Ani-mal" (using a soft hyphen, or U+00AD) indicates that the two strings are equivalent. :::code language="csharp" source="~/snippets/csharp/System/String/Compare/compare22.cs" id="Snippet22"::: :::code language="fsharp" source="~/snippets/fsharp/System/String/Compare/compare22.fs" id="Snippet22"::: @@ -8795,7 +8795,7 @@ The following example creates a string array, and then passes each element of th - The character to use as a separator. is included in the returned string only if has more than one element. + The character to use as a separator. is included in the returned string only if has more than one element. An array of objects whose string representations will be concatenated. Concatenates the string representations of an array of objects, using the specified separator between each member. A string that consists of the elements of delimited by the character. @@ -8805,7 +8805,7 @@ The following example creates a string array, and then passes each element of th if has zero elements. To be added. - is . + is . The length of the resulting string overflows the maximum allowed length (Int32.MaxValue). @@ -9356,7 +9356,7 @@ The following example uses the Sieve of Eratosthenes algorithm to calculate the -or- - if has zero elements. + if has zero elements. , and

and is less than -1 or greater than zero. +The current instance equals and is less than -1 or greater than zero. -or- @@ -10533,7 +10533,7 @@ The current instance does not equal , and

and is less than -1 or greater than zero. +The current instance equals and is less than -1 or greater than zero. -or- diff --git a/xml/System/TimeZoneInfo.xml b/xml/System/TimeZoneInfo.xml index d5a08dc9c64..e1a30c5c090 100644 --- a/xml/System/TimeZoneInfo.xml +++ b/xml/System/TimeZoneInfo.xml @@ -411,7 +411,7 @@ The date and time to convert. - The time zone to convert to. + The time zone to convert to.

Converts a time to the time in a particular time zone. The date and time in the destination time zone. diff --git a/xml/System/Type.xml b/xml/System/Type.xml index a3aa3de90e7..eab8d9bf4fb 100644 --- a/xml/System/Type.xml +++ b/xml/System/Type.xml @@ -10828,7 +10828,7 @@ Calling this method overload is the same as calling the
- is . + is . diff --git a/xml/System/UIntPtr.xml b/xml/System/UIntPtr.xml index f849b867e61..3553791999d 100644 --- a/xml/System/UIntPtr.xml +++ b/xml/System/UIntPtr.xml @@ -1333,8 +1333,7 @@ For this method matches the IEEE 754:2 Represents the largest possible value of . - - if it is greater than ; otherwise, . + The largest possible value of . To be added. @@ -1417,8 +1416,7 @@ For this method matches the IEEE 754:2 Represents the smallest possible value of . - - if it is less than ; otherwise, . + The smallest possible value of . To be added. diff --git a/xml/System/Uri.xml b/xml/System/Uri.xml index fb1550a2c8f..fd910874086 100644 --- a/xml/System/Uri.xml +++ b/xml/System/Uri.xml @@ -807,7 +807,7 @@ The following code snippet shows example values of the various properties on the -or- - The MS-DOS path specified in must start with c:\\\\. + The MS-DOS path specified in must start with c:\\\\. @@ -930,7 +930,7 @@ The URI formed by combining and must start with c:\\\\. + The MS-DOS path specified in must start with c:\\\\. @@ -995,7 +995,7 @@ The URI formed by combining and The base URI. The relative URI to add to the base URI. - if is completely escaped; otherwise, . + if and are completely escaped; otherwise, . Initializes a new instance of the class based on the specified base and relative URIs, with explicit control of character escaping. and must start with c:\\\\. + The MS-DOS path specified in must start with c:\\\\. Because of security concerns, your application should not call this constructor with URI strings from untrusted sources and with set to . Alternately, you can check a URI string for validity by calling the method prior to calling this constructor. diff --git a/xml/System/UriParser.xml b/xml/System/UriParser.xml index 91108b743d2..f0b1158da10 100644 --- a/xml/System/UriParser.xml +++ b/xml/System/UriParser.xml @@ -52,13 +52,13 @@ Parses a new URI scheme. This is an abstract class. - . If you want to create a parser that extends a well-known URI scheme, inherit from , , , , or . - - Microsoft strongly recommends that you use a parser shipped with .NET. Building your own parser increases the complexity of your application, and will not perform as well as the shipped parsers. - + . If you want to create a parser that extends a well-known URI scheme, inherit from , , , , or . + + Microsoft strongly recommends that you use a parser shipped with .NET. Building your own parser increases the complexity of your application, and will not perform as well as the shipped parsers. + ]]> @@ -149,26 +149,26 @@ Gets the components from a URI. A string that contains the components. - method to determine the value of various parts of the URI, such as the , , or . - - The components are returned in the order that they appear in the URI. For example, if is specified, it appears first. - + method to determine the value of various parts of the URI, such as the , , or . + + The components are returned in the order that they appear in the URI. For example, if is specified, it appears first. + ]]> - is invalid. - + is invalid. + -or- - - is not a combination of valid values. + + is not a combination of valid values. - requires user-driven parsing - + requires user-driven parsing + -or- - + is not an absolute URI. Relative URIs cannot be used with this method. @@ -228,11 +228,11 @@ When this method returns, contains the validation errors, if any. Initialize the state of the parser and validate the URI. - method is called every time a is instantiated. - + method is called every time a is instantiated. + ]]> @@ -371,19 +371,19 @@ if is well-formed; otherwise, . - method will return false if: - -- The string is not correctly escaped per RFC 2396. - -- The string represents an absolute URI that references an implicit file URI. - -- The string represents an absolute URI that is missing a forward slash before the path component. - -- The string contains unescaped backslashes, even if they will be treated as forward slashes. - + method will return false if: + +- The string is not correctly escaped per RFC 2396. + +- The string represents an absolute URI that references an implicit file URI. + +- The string represents an absolute URI that is missing a forward slash before the path component. + +- The string contains unescaped backslashes, even if they will be treated as forward slashes. + ]]> @@ -426,11 +426,11 @@ Invoked by a constructor to get a instance. A for the constructed . - instance. You may need to override this method and return a different for each invocation if you are operating in a multithreaded environment. - + instance. You may need to override this method and return a different for each invocation if you are operating in a multithreaded environment. + ]]> @@ -523,24 +523,24 @@ The default port number for the specified scheme. Associates a scheme and port number with a . - method registers no default value for the port number. - + method registers no default value for the port number. + ]]> - parameter is null - + parameter is null + -or- - + parameter is null. - parameter is not valid - + parameter is not valid + -or- - + parameter is not valid. The parameter is less than -1 or greater than 65,534. @@ -603,20 +603,20 @@ Called by constructors and to resolve a relative URI. The string of the resolved relative . - constructors and use to construct a URI from `baseUri` and `relativeUri`. - - If a parsing error occurs, the returned string for the resolved relative is null. - + constructors and use to construct a URI from `baseUri` and `relativeUri`. + + If a parsing error occurs, the returned string for the resolved relative is null. + ]]> - parameter is not an absolute - + parameter is not an absolute + -or- - + parameter requires user-driven parsing. diff --git a/xml/System/ValueTuple`1.xml b/xml/System/ValueTuple`1.xml index 3017046b23d..a8b6983aca9 100644 --- a/xml/System/ValueTuple`1.xml +++ b/xml/System/ValueTuple`1.xml @@ -676,7 +676,7 @@ The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`2.xml b/xml/System/ValueTuple`2.xml index 48288936280..22e4cec3dfa 100644 --- a/xml/System/ValueTuple`2.xml +++ b/xml/System/ValueTuple`2.xml @@ -746,7 +746,7 @@ The The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`3.xml b/xml/System/ValueTuple`3.xml index 3894cb95fbf..1fff9edd679 100644 --- a/xml/System/ValueTuple`3.xml +++ b/xml/System/ValueTuple`3.xml @@ -794,7 +794,7 @@ The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`4.xml b/xml/System/ValueTuple`4.xml index 6645895ff0b..c32aa0c9fb3 100644 --- a/xml/System/ValueTuple`4.xml +++ b/xml/System/ValueTuple`4.xml @@ -830,7 +830,7 @@ The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`5.xml b/xml/System/ValueTuple`5.xml index 4251163d3e0..4e182f26a1d 100644 --- a/xml/System/ValueTuple`5.xml +++ b/xml/System/ValueTuple`5.xml @@ -882,7 +882,7 @@ The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`6.xml b/xml/System/ValueTuple`6.xml index e1960b1f510..62371122cc8 100644 --- a/xml/System/ValueTuple`6.xml +++ b/xml/System/ValueTuple`6.xml @@ -934,7 +934,7 @@ The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`7.xml b/xml/System/ValueTuple`7.xml index 1a78d7262af..750eb33e8a2 100644 --- a/xml/System/ValueTuple`7.xml +++ b/xml/System/ValueTuple`7.xml @@ -986,7 +986,7 @@ The object to compare with the current instance. Compares the current instance to a specified object by using a specified comparer and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/System/ValueTuple`8.xml b/xml/System/ValueTuple`8.xml index 3e301aed28b..534b9bbd5cb 100644 --- a/xml/System/ValueTuple`8.xml +++ b/xml/System/ValueTuple`8.xml @@ -1108,7 +1108,7 @@ An object to compare with the current instance. Compares the current object to a specified object and returns an integer that indicates whether the current object is before, after, or in the same position as the specified object in the sort order. - A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. + A signed integer that indicates the relative position of this instance and in the sort order, as shown in the following table. Value diff --git a/xml/index.xml b/xml/index.xml index 9fecfbfb00a..1fa6b3cf96a 100644 --- a/xml/index.xml +++ b/xml/index.xml @@ -213580,7 +213580,7 @@ The type of the items in the . The source . The item to find in the . - Returns the position of the first occurrence of in the . + Returns the position of the first occurrence of in the . @@ -223051,7 +223051,7 @@ A generic parameter that specifies the value type of the column. The input , which acts as the instance for the extension method. The input specifies which row value to retrieve. - The new row value for the specified column, of type . + The new row value for the specified column, of type . Sets a new value for the specified column in the . The method also supports nullable types. @@ -223084,7 +223084,7 @@ A generic parameter that specifies the value type of the column. The input , which acts as the instance for the extension method. The zero-based ordinal of the column to set the value of. - The new row value for the specified column, of type . + The new row value for the specified column, of type . Sets a new value for the specified column in the the method is called on. The method also supports nullable types. @@ -223117,7 +223117,7 @@ A generic parameter that specifies the value type of the column. The input , which acts as the instance for the extension method. The name of the column to set the value of. - The new row value for the specified column, of type . + The new row value for the specified column, of type . Sets a new value for the specified column in the . The method also supports nullable types. @@ -223201,7 +223201,7 @@ The source to make enumerable. - Returns an object, where the generic parameter is . This object can be used in a LINQ expression or method query. + Returns an object, where the generic parameter is . This object can be used in a LINQ expression or method query. @@ -223234,7 +223234,7 @@ The type of objects in the source sequence, typically . The source sequence. - Returns a that contains copies of the objects, given an input object where the generic parameter is . + Returns a that contains copies of the objects, given an input object where the generic parameter is . @@ -223271,7 +223271,7 @@ The source sequence. The destination . A enumeration that specifies the load options. - Copies objects to the specified , given an input object where the generic parameter is . + Copies objects to the specified , given an input object where the generic parameter is . @@ -223310,7 +223310,7 @@ The destination . A enumeration that specifies the load options. A delegate that represents the method that will handle an error. - Copies objects to the specified , given an input object where the generic parameter is . + Copies objects to the specified , given an input object where the generic parameter is . @@ -223532,7 +223532,7 @@ The type of the row elements in , typically . - The type that will be transformed into. + The type that will be transformed into. An containing the elements to invoke a transform function upon. A transform function to apply to each element. Projects each element of an into a new form. @@ -223735,7 +223735,7 @@ The type to convert the elements of the source to. The source to make enumerable. - Enumerates the data row elements of the and returns an object, where the generic parameter is . This object can be used in a LINQ expression or method query. + Enumerates the data row elements of the and returns an object, where the generic parameter is . This object can be used in a LINQ expression or method query. @@ -225887,7 +225887,7 @@ The type to cast the elements of to. - The that contains the elements to be cast to type . + The that contains the elements to be cast to type . Casts the elements of an to the specified type. @@ -241225,7 +241225,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of values that is obtained by invoking a projection function on each element of the input sequence. @@ -241256,7 +241256,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of values that is obtained by invoking a projection function on each element of the input sequence. @@ -241287,7 +241287,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of values that is obtained by invoking a projection function on each element of the input sequence. @@ -241318,7 +241318,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of values that is obtained by invoking a projection function on each element of the input sequence. @@ -241349,7 +241349,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of nullable values that is obtained by invoking a projection function on each element of the input sequence. @@ -241380,7 +241380,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of nullable values that is obtained by invoking a projection function on each element of the input sequence. @@ -241411,7 +241411,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of nullable values that is obtained by invoking a projection function on each element of the input sequence. @@ -241442,7 +241442,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of nullable values that is obtained by invoking a projection function on each element of the input sequence. @@ -241473,7 +241473,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of nullable values that is obtained by invoking a projection function on each element of the input sequence. @@ -241504,7 +241504,7 @@ The type of the elements of . - A sequence of values of type . + A sequence of values of type . A projection function to apply to each element. Computes the sum of the sequence of values that is obtained by invoking a projection function on each element of the input sequence.