Dictionary<​TKey,​TValue> Class

Definition

Represents a collection of keys and values.

[System.Runtime.InteropServices.ComVisible(false)]
public class Dictionary<TKey,TValue> : System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>, System.Collections.Generic.IDictionary<TKey,TValue>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TKey,TValue>>, System.Collections.Generic.IReadOnlyCollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>, System.Collections.Generic.IReadOnlyDictionary<TKey,TValue>, System.Collections.IDictionary, System.Runtime.Serialization.IDeserializationCallback, System.Runtime.Serialization.ISerializable
Type Parameters
TKey

The type of the keys in the dictionary.

TValue

The type of the values in the dictionary.

Inheritance
Dictionary<TKey,TValue>
Derived
Attributes
Implements
System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>> System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>> System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TKey,TValue>> System.Collections.Generic.IReadOnlyCollection<System.Collections.Generic.KeyValuePair<TKey,TValue>> System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>> IDictionary IDeserializationCallback ISerializable

Inherited Members

System.Object

Examples

The following code example creates an empty Dictionary<TKey,TValue> of strings with string keys and uses the Add method to add some elements. The example demonstrates that the Add method throws an ArgumentException when attempting to add a duplicate key.

The example uses the Item property (the indexer in C#) to retrieve values, demonstrating that a KeyNotFoundException is thrown when a requested key is not present, and showing that the value associated with a key can be replaced.

The example shows how to use the TryGetValue method as a more efficient way to retrieve values if a program often must try key values that are not in the dictionary, and it shows how to use the ContainsKey method to test whether a key exists before calling the Add method.

The example shows how to enumerate the keys and values in the dictionary and how to enumerate the keys and values alone using the Keys property and the Values property.

Finally, the example demonstrates the Remove method.

using namespace System;
using namespace System::Collections::Generic;

public ref class Example
{
public:
    static void Main()
    {
        // Create a new dictionary of strings, with string keys.
        //
        Dictionary<String^, String^>^ openWith =
            gcnew Dictionary<String^, String^>();

        // Add some elements to the dictionary. There are no
        // duplicate keys, but some of the values are duplicates.
        openWith->Add("txt", "notepad.exe");
        openWith->Add("bmp", "paint.exe");
        openWith->Add("dib", "paint.exe");
        openWith->Add("rtf", "wordpad.exe");

        // The Add method throws an exception if the new key is
        // already in the dictionary.
        try
        {
            openWith->Add("txt", "winword.exe");
        }
        catch (ArgumentException^)
        {
            Console::WriteLine("An element with Key = \"txt\" already exists.");
        }

        // The Item property is another name for the indexer, so you
        // can omit its name when accessing elements.
        Console::WriteLine("For key = \"rtf\", value = {0}.",
            openWith["rtf"]);

        // The indexer can be used to change the value associated
        // with a key.
        openWith["rtf"] = "winword.exe";
        Console::WriteLine("For key = \"rtf\", value = {0}.",
            openWith["rtf"]);

        // If a key does not exist, setting the indexer for that key
        // adds a new key/value pair.
        openWith["doc"] = "winword.exe";

        // The indexer throws an exception if the requested key is
        // not in the dictionary.
        try
        {
            Console::WriteLine("For key = \"tif\", value = {0}.",
                openWith["tif"]);
        }
        catch (KeyNotFoundException^)
        {
            Console::WriteLine("Key = \"tif\" is not found.");
        }

        // When a program often has to try keys that turn out not to
        // be in the dictionary, TryGetValue can be a more efficient
        // way to retrieve values.
        String^ value = "";
        if (openWith->TryGetValue("tif", value))
        {
            Console::WriteLine("For key = \"tif\", value = {0}.", value);
        }
        else
        {
            Console::WriteLine("Key = \"tif\" is not found.");
        }

        // ContainsKey can be used to test keys before inserting
        // them.
        if (!openWith->ContainsKey("ht"))
        {
            openWith->Add("ht", "hypertrm.exe");
            Console::WriteLine("Value added for key = \"ht\": {0}",
                openWith["ht"]);
        }

        // When you use foreach to enumerate dictionary elements,
        // the elements are retrieved as KeyValuePair objects.
        Console::WriteLine();
        for each( KeyValuePair<String^, String^> kvp in openWith )
        {
            Console::WriteLine("Key = {0}, Value = {1}",
                kvp.Key, kvp.Value);
        }

        // To get the values alone, use the Values property.
        Dictionary<String^, String^>::ValueCollection^ valueColl =
            openWith->Values;

        // The elements of the ValueCollection are strongly typed
        // with the type that was specified for dictionary values.
        Console::WriteLine();
        for each( String^ s in valueColl )
        {
            Console::WriteLine("Value = {0}", s);
        }

        // To get the keys alone, use the Keys property.
        Dictionary<String^, String^>::KeyCollection^ keyColl =
            openWith->Keys;

        // The elements of the KeyCollection are strongly typed
        // with the type that was specified for dictionary keys.
        Console::WriteLine();
        for each( String^ s in keyColl )
        {
            Console::WriteLine("Key = {0}", s);
        }

        // Use the Remove method to remove a key/value pair.
        Console::WriteLine("\nRemove(\"doc\")");
        openWith->Remove("doc");

        if (!openWith->ContainsKey("doc"))
        {
            Console::WriteLine("Key \"doc\" is not found.");
        }
    }
};

int main()
{
    Example::Main();
}

/* This code example produces the following output:

An element with Key = "txt" already exists.
For key = "rtf", value = wordpad.exe.
For key = "rtf", value = winword.exe.
Key = "tif" is not found.
Key = "tif" is not found.
Value added for key = "ht": hypertrm.exe

Key = txt, Value = notepad.exe
Key = bmp, Value = paint.exe
Key = dib, Value = paint.exe
Key = rtf, Value = winword.exe
Key = doc, Value = winword.exe
Key = ht, Value = hypertrm.exe

Value = notepad.exe
Value = paint.exe
Value = paint.exe
Value = winword.exe
Value = winword.exe
Value = hypertrm.exe

Key = txt
Key = bmp
Key = dib
Key = rtf
Key = doc
Key = ht

Remove("doc")
Key "doc" is not found.
 */
using System;
using System.Collections.Generic;

public class Example
{
    public static void Main()
    {
        // Create a new dictionary of strings, with string keys.
        //
        Dictionary<string, string> openWith = 
            new Dictionary<string, string>();

        // Add some elements to the dictionary. There are no 
        // duplicate keys, but some of the values are duplicates.
        openWith.Add("txt", "notepad.exe");
        openWith.Add("bmp", "paint.exe");
        openWith.Add("dib", "paint.exe");
        openWith.Add("rtf", "wordpad.exe");

        // The Add method throws an exception if the new key is 
        // already in the dictionary.
        try
        {
            openWith.Add("txt", "winword.exe");
        }
        catch (ArgumentException)
        {
            Console.WriteLine("An element with Key = \"txt\" already exists.");
        }

        // The Item property is another name for the indexer, so you 
        // can omit its name when accessing elements. 
        Console.WriteLine("For key = \"rtf\", value = {0}.", 
            openWith["rtf"]);

        // The indexer can be used to change the value associated
        // with a key.
        openWith["rtf"] = "winword.exe";
        Console.WriteLine("For key = \"rtf\", value = {0}.", 
            openWith["rtf"]);

        // If a key does not exist, setting the indexer for that key
        // adds a new key/value pair.
        openWith["doc"] = "winword.exe";

        // The indexer throws an exception if the requested key is
        // not in the dictionary.
        try
        {
            Console.WriteLine("For key = \"tif\", value = {0}.", 
                openWith["tif"]);
        }
        catch (KeyNotFoundException)
        {
            Console.WriteLine("Key = \"tif\" is not found.");
        }

        // When a program often has to try keys that turn out not to
        // be in the dictionary, TryGetValue can be a more efficient 
        // way to retrieve values.
        string value = "";
        if (openWith.TryGetValue("tif", out value))
        {
            Console.WriteLine("For key = \"tif\", value = {0}.", value);
        }
        else
        {
            Console.WriteLine("Key = \"tif\" is not found.");
        }

        // ContainsKey can be used to test keys before inserting 
        // them.
        if (!openWith.ContainsKey("ht"))
        {
            openWith.Add("ht", "hypertrm.exe");
            Console.WriteLine("Value added for key = \"ht\": {0}", 
                openWith["ht"]);
        }

        // When you use foreach to enumerate dictionary elements,
        // the elements are retrieved as KeyValuePair objects.
        Console.WriteLine();
        foreach( KeyValuePair<string, string> kvp in openWith )
        {
            Console.WriteLine("Key = {0}, Value = {1}", 
                kvp.Key, kvp.Value);
        }

        // To get the values alone, use the Values property.
        Dictionary<string, string>.ValueCollection valueColl =
            openWith.Values;

        // The elements of the ValueCollection are strongly typed
        // with the type that was specified for dictionary values.
        Console.WriteLine();
        foreach( string s in valueColl )
        {
            Console.WriteLine("Value = {0}", s);
        }

        // To get the keys alone, use the Keys property.
        Dictionary<string, string>.KeyCollection keyColl =
            openWith.Keys;

        // The elements of the KeyCollection are strongly typed
        // with the type that was specified for dictionary keys.
        Console.WriteLine();
        foreach( string s in keyColl )
        {
            Console.WriteLine("Key = {0}", s);
        }

        // Use the Remove method to remove a key/value pair.
        Console.WriteLine("\nRemove(\"doc\")");
        openWith.Remove("doc");

        if (!openWith.ContainsKey("doc"))
        {
            Console.WriteLine("Key \"doc\" is not found.");
        }
    }
}

/* This code example produces the following output:

An element with Key = "txt" already exists.
For key = "rtf", value = wordpad.exe.
For key = "rtf", value = winword.exe.
Key = "tif" is not found.
Key = "tif" is not found.
Value added for key = "ht": hypertrm.exe

Key = txt, Value = notepad.exe
Key = bmp, Value = paint.exe
Key = dib, Value = paint.exe
Key = rtf, Value = winword.exe
Key = doc, Value = winword.exe
Key = ht, Value = hypertrm.exe

Value = notepad.exe
Value = paint.exe
Value = paint.exe
Value = winword.exe
Value = winword.exe
Value = hypertrm.exe

Key = txt
Key = bmp
Key = dib
Key = rtf
Key = doc
Key = ht

Remove("doc")
Key "doc" is not found.
 */
Imports System
Imports System.Collections.Generic

Public Class Example
    
    Public Shared Sub Main() 

        ' Create a new dictionary of strings, with string keys.
        '
        Dim openWith As New Dictionary(Of String, String)
        
        ' Add some elements to the dictionary. There are no 
        ' duplicate keys, but some of the values are duplicates.
        openWith.Add("txt", "notepad.exe")
        openWith.Add("bmp", "paint.exe")
        openWith.Add("dib", "paint.exe")
        openWith.Add("rtf", "wordpad.exe")
        
        ' The Add method throws an exception if the new key is 
        ' already in the dictionary.
        Try
            openWith.Add("txt", "winword.exe")
        Catch 
            Console.WriteLine("An element with Key = ""txt"" already exists.")
        End Try

        ' The Item property is the default property, so you 
        ' can omit its name when accessing elements. 
        Console.WriteLine("For key = ""rtf"", value = {0}.", _
            openWith("rtf"))
        
        ' The default Item property can be used to change the value
        ' associated with a key.
        openWith("rtf") = "winword.exe"
        Console.WriteLine("For key = ""rtf"", value = {0}.", _
            openWith("rtf"))
        
        ' If a key does not exist, setting the default Item property
        ' for that key adds a new key/value pair.
        openWith("doc") = "winword.exe"

        ' The default Item property throws an exception if the requested
        ' key is not in the dictionary.
        Try
            Console.WriteLine("For key = ""tif"", value = {0}.", _
                openWith("tif"))
        Catch 
            Console.WriteLine("Key = ""tif"" is not found.")
        End Try

        ' When a program often has to try keys that turn out not to
        ' be in the dictionary, TryGetValue can be a more efficient 
        ' way to retrieve values.
        Dim value As String = ""
        If openWith.TryGetValue("tif", value) Then
            Console.WriteLine("For key = ""tif"", value = {0}.", value)
        Else
            Console.WriteLine("Key = ""tif"" is not found.")
        End If

        ' ContainsKey can be used to test keys before inserting 
        ' them.
        If Not openWith.ContainsKey("ht") Then
            openWith.Add("ht", "hypertrm.exe")
            Console.WriteLine("Value added for key = ""ht"": {0}", _
                openWith("ht"))
        End If

        ' When you use foreach to enumerate dictionary elements,
        ' the elements are retrieved as KeyValuePair objects.
        Console.WriteLine()
        For Each kvp As KeyValuePair(Of String, String) In openWith
            Console.WriteLine("Key = {0}, Value = {1}", _
                kvp.Key, kvp.Value)
        Next kvp

        ' To get the values alone, use the Values property.
        Dim valueColl As _
            Dictionary(Of String, String).ValueCollection = _
            openWith.Values
        
        ' The elements of the ValueCollection are strongly typed
        ' with the type that was specified for dictionary values.
        Console.WriteLine()
        For Each s As String In  valueColl
            Console.WriteLine("Value = {0}", s)
        Next s

        ' To get the keys alone, use the Keys property.
        Dim keyColl As _
            Dictionary(Of String, String).KeyCollection = _
            openWith.Keys
        
        ' The elements of the KeyCollection are strongly typed
        ' with the type that was specified for dictionary keys.
        Console.WriteLine()
        For Each s As String In  keyColl
            Console.WriteLine("Key = {0}", s)
        Next s

        ' Use the Remove method to remove a key/value pair.
        Console.WriteLine(vbLf + "Remove(""doc"")")
        openWith.Remove("doc")
        
        If Not openWith.ContainsKey("doc") Then
            Console.WriteLine("Key ""doc"" is not found.")
        End If

    End Sub

End Class

' This code example produces the following output:
'
'An element with Key = "txt" already exists.
'For key = "rtf", value = wordpad.exe.
'For key = "rtf", value = winword.exe.
'Key = "tif" is not found.
'Key = "tif" is not found.
'Value added for key = "ht": hypertrm.exe
'
'Key = txt, Value = notepad.exe
'Key = bmp, Value = paint.exe
'Key = dib, Value = paint.exe
'Key = rtf, Value = winword.exe
'Key = doc, Value = winword.exe
'Key = ht, Value = hypertrm.exe
'
'Value = notepad.exe
'Value = paint.exe
'Value = paint.exe
'Value = winword.exe
'Value = winword.exe
'Value = hypertrm.exe
'
'Key = txt
'Key = bmp
'Key = dib
'Key = rtf
'Key = doc
'Key = ht
'
'Remove("doc")
'Key "doc" is not found.
' 

Remarks

Note

To view the .NET Framework source code for this type, see the Reference Source. You can browse through the source code online, download the reference for offline viewing, and step through the sources (including patches and updates) during debugging; see instructions.

The Dictionary<TKey,TValue> generic class provides a mapping from a set of keys to a set of values. Each addition to the dictionary consists of a value and its associated key. Retrieving a value by using its key is very fast, close to O(1), because the Dictionary<TKey,TValue> class is implemented as a hash table.

Note

The speed of retrieval depends on the quality of the hashing algorithm of the type specified for TKey.

As long as an object is used as a key in the Dictionary<TKey,TValue>, it must not change in any way that affects its hash value. Every key in a Dictionary<TKey,TValue> must be unique according to the dictionary's equality comparer. A key cannot be null, but a value can be, if the value type TValue is a reference type.

Dictionary<TKey,TValue> requires an equality implementation to determine whether keys are equal. You can specify an implementation of the IEqualityComparer<T> generic interface by using a constructor that accepts a comparer parameter; if you do not specify an implementation, the default generic equality comparer System.Collections.Generic.EqualityComparer<T>.Default is used. If type TKey implements the System.IEquatable<T> generic interface, the default equality comparer uses that implementation.

Note

For example, you can use the case-insensitive string comparers provided by the StringComparer class to create dictionaries with case-insensitive string keys.

The capacity of a Dictionary<TKey,TValue> is the number of elements the Dictionary<TKey,TValue> can hold. As elements are added to a Dictionary<TKey,TValue>, the capacity is automatically increased as required by reallocating the internal array.

For very large Dictionary<TKey,TValue> objects, you can increase the maximum capacity to 2 billion elements on a 64-bit system by setting the enabled attribute of the configuration element to true in the run-time environment.

For purposes of enumeration, each item in the dictionary is treated as a KeyValuePair<TKey,TValue> structure representing a value and its key. The order in which the items are returned is undefined.

The foreach statement of the C# language (for each in C++, For Each in Visual Basic) returns an object of the type of the elements in the collection. Since the Dictionary<TKey,TValue> is a collection of keys and values, the element type is not the type of the key or the type of the value. Instead, the element type is a KeyValuePair<TKey,TValue> of the key type and the value type. For example:

for each(KeyValuePair<String^, String^> kvp in myDictionary)
{
    Console::WriteLine("Key = {0}, Value = {1}", kvp.Key, kvp.Value);
}
foreach( KeyValuePair<string, string> kvp in myDictionary )
{
    Console.WriteLine("Key = {0}, Value = {1}", kvp.Key, kvp.Value);
}
For Each kvp As KeyValuePair(Of String, String) In myDictionary
    Console.WriteLine("Key = {0}, Value = {1}", kvp.Key, kvp.Value)
Next kvp

The foreach statement is a wrapper around the enumerator, which allows only reading from the collection, not writing to it.

Note

Because keys can be inherited and their behavior changed, their absolute uniqueness cannot be guaranteed by comparisons using the Equals method.

Constructors

Dictionary<​TKey,​TValue>()

Initializes a new instance of the Dictionary<TKey,TValue> class that is empty, has the default initial capacity, and uses the default equality comparer for the key type.

Dictionary<​TKey,​TValue>(​IDictionary<​TKey,​TValue>)

Initializes a new instance of the Dictionary<TKey,TValue> class that contains elements copied from the specified IDictionary<TKey,TValue> and uses the default equality comparer for the key type.

Dictionary<​TKey,​TValue>(​IEnumerable<​Key​Value​Pair<​TKey,​TValue>>)
Dictionary<​TKey,​TValue>(​IEquality​Comparer<​TKey>)

Initializes a new instance of the Dictionary<TKey,TValue> class that is empty, has the default initial capacity, and uses the specified IEqualityComparer<T>.

Dictionary<​TKey,​TValue>(​Int32)

Initializes a new instance of the Dictionary<TKey,TValue> class that is empty, has the specified initial capacity, and uses the default equality comparer for the key type.

Dictionary<​TKey,​TValue>(​IDictionary<​TKey,​TValue>, ​IEquality​Comparer<​TKey>)

Initializes a new instance of the Dictionary<TKey,TValue> class that contains elements copied from the specified IDictionary<TKey,TValue> and uses the specified IEqualityComparer<T>.

Dictionary<​TKey,​TValue>(​IEnumerable<​Key​Value​Pair<​TKey,​TValue>>, ​IEquality​Comparer<​TKey>)
Dictionary<​TKey,​TValue>(​Int32, ​IEquality​Comparer<​TKey>)

Initializes a new instance of the Dictionary<TKey,TValue> class that is empty, has the specified initial capacity, and uses the specified IEqualityComparer<T>.

Dictionary<​TKey,​TValue>(​Serialization​Info, ​Streaming​Context)

Initializes a new instance of the Dictionary<TKey,TValue> class with serialized data.

Properties

Comparer

Gets the IEqualityComparer<T> that is used to determine equality of keys for the dictionary.

Count

Gets the number of key/value pairs contained in the Dictionary<TKey,TValue>.

Item(​TKey)

Gets or sets the value associated with the specified key.

Keys

Gets a collection containing the keys in the Dictionary<TKey,TValue>.

Values

Gets a collection containing the values in the Dictionary<TKey,TValue>.

Methods

Add(​TKey, ​TValue)

Adds the specified key and value to the dictionary.

Clear()

Removes all keys and values from the Dictionary<TKey,TValue>.

Contains​Key(​TKey)

Determines whether the Dictionary<TKey,TValue> contains the specified key.

Contains​Value(​TValue)

Determines whether the Dictionary<TKey,TValue> contains a specific value.

Get​Enumerator()

Returns an enumerator that iterates through the Dictionary<TKey,TValue>.

Get​Object​Data(​Serialization​Info, ​Streaming​Context)

Implements the ISerializable interface and returns the data needed to serialize the Dictionary<TKey,TValue> instance.

On​Deserialization(​Object)

Implements the ISerializable interface and raises the deserialization event when the deserialization is complete.

Remove(​TKey)

Removes the value with the specified key from the Dictionary<TKey,TValue>.

Remove(​TKey, ​TValue)
Try​Add(​TKey, ​TValue)
Try​Get​Value(​TKey, ​TValue)

Gets the value associated with the specified key.

Explicit Interface Implementations

I​Collection<​Key​Value​Pair<​TKey,​TValue>>.​Add(​Key​Value​Pair<​TKey,​TValue>)
I​Collection<​Key​Value​Pair<​TKey,​TValue>>.​Contains(​Key​Value​Pair<​TKey,​TValue>)
I​Collection<​Key​Value​Pair<​TKey,​TValue>>.​Copy​To(​Key​Value​Pair<​TKey,​TValue>[], ​Int32)
I​Collection<​Key​Value​Pair<​TKey,​TValue>>.​Is​Read​Only
I​Collection<​Key​Value​Pair<​TKey,​TValue>>.​Remove(​Key​Value​Pair<​TKey,​TValue>)
I​Dictionary<​TKey,​TValue>.​Keys
I​Dictionary<​TKey,​TValue>.​Values
I​Enumerable<​Key​Value​Pair<​TKey,​TValue>>.​Get​Enumerator()
I​Read​Only​Dictionary<​TKey,​TValue>.​Keys
I​Read​Only​Dictionary<​TKey,​TValue>.​Values
I​Collection.​Copy​To(​Array, ​Int32)

Copies the elements of the ICollection<T> to an array, starting at the specified array index.

I​Collection.​Is​Synchronized

Gets a value indicating whether access to the ICollection is synchronized (thread safe).

I​Collection.​Sync​Root

Gets an object that can be used to synchronize access to the ICollection.

I​Dictionary.​Add(​Object, ​Object)

Adds the specified key and value to the dictionary.

I​Dictionary.​Contains(​Object)

Determines whether the IDictionary contains an element with the specified key.

I​Dictionary.​Get​Enumerator()

Returns an IDictionaryEnumerator for the IDictionary.

I​Dictionary.​Is​Fixed​Size

Gets a value indicating whether the IDictionary has a fixed size.

I​Dictionary.​Is​Read​Only

Gets a value indicating whether the IDictionary is read-only.

I​Dictionary.​Item(​Object)

Gets or sets the value with the specified key.

I​Dictionary.​Keys

Gets an ICollection containing the keys of the IDictionary.

I​Dictionary.​Remove(​Object)

Removes the element with the specified key from the IDictionary.

I​Dictionary.​Values

Gets an ICollection containing the values in the IDictionary.

I​Enumerable.​Get​Enumerator()

Returns an enumerator that iterates through the collection.

Extension Methods

GetValueOrDefault<TKey,TValue>(IReadOnlyDictionary<TKey,TValue>, TKey)

Represents a collection of keys and values.

GetValueOrDefault<TKey,TValue>(IReadOnlyDictionary<TKey,TValue>, TKey, TValue)

Represents a collection of keys and values.

Remove<TKey,TValue>(IDictionary<TKey,TValue>, TKey, TValue)

Represents a collection of keys and values.

TryAdd<TKey,TValue>(IDictionary<TKey,TValue>, TKey, TValue)

Represents a collection of keys and values.

ToImmutableArray<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToImmutableDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

Represents a collection of keys and values.

ToImmutableDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

ToImmutableDictionary<TKey,TValue>(IEnumerable<KeyValuePair<TKey,TValue>>)

Represents a collection of keys and values.

ToImmutableDictionary<TKey,TValue>(IEnumerable<KeyValuePair<TKey,TValue>>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

ToImmutableDictionary<TKey,TValue>(IEnumerable<KeyValuePair<TKey,TValue>>, IEqualityComparer<TKey>, IEqualityComparer<TValue>)

Represents a collection of keys and values.

ToImmutableDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>)

Represents a collection of keys and values.

ToImmutableDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

ToImmutableDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IEqualityComparer<TKey>, IEqualityComparer<TValue>)

Represents a collection of keys and values.

ToImmutableHashSet<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToImmutableHashSet<TSource>(IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

ToImmutableList<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToImmutableSortedDictionary<TKey,TValue>(IEnumerable<KeyValuePair<TKey,TValue>>)

Represents a collection of keys and values.

ToImmutableSortedDictionary<TKey,TValue>(IEnumerable<KeyValuePair<TKey,TValue>>, IComparer<TKey>)

Represents a collection of keys and values.

ToImmutableSortedDictionary<TKey,TValue>(IEnumerable<KeyValuePair<TKey,TValue>>, IComparer<TKey>, IEqualityComparer<TValue>)

Represents a collection of keys and values.

ToImmutableSortedDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>)

Represents a collection of keys and values.

ToImmutableSortedDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IComparer<TKey>)

Represents a collection of keys and values.

ToImmutableSortedDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IComparer<TKey>, IEqualityComparer<TValue>)

Represents a collection of keys and values.

ToImmutableSortedSet<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToImmutableSortedSet<TSource>(IEnumerable<TSource>, IComparer<TSource>)

Represents a collection of keys and values.

CopyToDataTable<T>(IEnumerable<T>)

Represents a collection of keys and values.

CopyToDataTable<T>(IEnumerable<T>, DataTable, LoadOption)

Represents a collection of keys and values.

CopyToDataTable<T>(IEnumerable<T>, DataTable, LoadOption, FillErrorEventHandler)

Represents a collection of keys and values.

Aggregate<TSource>(IEnumerable<TSource>, Func<TSource,TSource,TSource>)

Represents a collection of keys and values.

Aggregate<TSource,TAccumulate>(IEnumerable<TSource>, TAccumulate, Func<TAccumulate,TSource,TAccumulate>)

Represents a collection of keys and values.

Aggregate<TSource,TAccumulate,TResult>(IEnumerable<TSource>, TAccumulate, Func<TAccumulate,TSource,TAccumulate>, Func<TAccumulate,TResult>)

Represents a collection of keys and values.

All<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

Any<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Any<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

Append<TSource>(IEnumerable<TSource>, TSource)

Represents a collection of keys and values.

AsEnumerable<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Average(IEnumerable<Decimal>)

Represents a collection of keys and values.

Average(IEnumerable<Double>)

Represents a collection of keys and values.

Average(IEnumerable<Int32>)

Represents a collection of keys and values.

Average(IEnumerable<Int64>)

Represents a collection of keys and values.

Average(IEnumerable<Nullable<Decimal>>)

Represents a collection of keys and values.

Average(IEnumerable<Nullable<Double>>)

Represents a collection of keys and values.

Average(IEnumerable<Nullable<Int32>>)

Represents a collection of keys and values.

Average(IEnumerable<Nullable<Int64>>)

Represents a collection of keys and values.

Average(IEnumerable<Nullable<Single>>)

Represents a collection of keys and values.

Average(IEnumerable<Single>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

Represents a collection of keys and values.

Average<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

Represents a collection of keys and values.

Cast<TResult>(IEnumerable)

Represents a collection of keys and values.

Concat<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

Represents a collection of keys and values.

Contains<TSource>(IEnumerable<TSource>, TSource)

Represents a collection of keys and values.

Contains<TSource>(IEnumerable<TSource>, TSource, IEqualityComparer<TSource>)

Represents a collection of keys and values.

Count<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Count<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

DefaultIfEmpty<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

DefaultIfEmpty<TSource>(IEnumerable<TSource>, TSource)

Represents a collection of keys and values.

Distinct<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Distinct<TSource>(IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

ElementAt<TSource>(IEnumerable<TSource>, Int32)

Represents a collection of keys and values.

ElementAtOrDefault<TSource>(IEnumerable<TSource>, Int32)

Represents a collection of keys and values.

Except<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

Represents a collection of keys and values.

Except<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

First<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

First<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

FirstOrDefault<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

FirstOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

GroupBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

Represents a collection of keys and values.

GroupBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

GroupBy<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>)

Represents a collection of keys and values.

GroupBy<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

GroupBy<TSource,TKey,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TKey,IEnumerable<TSource>,TResult>)

Represents a collection of keys and values.

GroupBy<TSource,TKey,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TKey,IEnumerable<TSource>,TResult>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

GroupBy<TSource,TKey,TElement,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, Func<TKey,IEnumerable<TElement>,TResult>)

Represents a collection of keys and values.

GroupBy<TSource,TKey,TElement,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, Func<TKey,IEnumerable<TElement>,TResult>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

GroupJoin<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,IEnumerable<TInner>,TResult>)

Represents a collection of keys and values.

GroupJoin<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,IEnumerable<TInner>,TResult>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

Intersect<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

Represents a collection of keys and values.

Intersect<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

Join<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,TInner,TResult>)

Represents a collection of keys and values.

Join<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,TInner,TResult>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

Last<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Last<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

LastOrDefault<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

LastOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

LongCount<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

LongCount<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

Max(IEnumerable<Decimal>)

Represents a collection of keys and values.

Max(IEnumerable<Double>)

Represents a collection of keys and values.

Max(IEnumerable<Int32>)

Represents a collection of keys and values.

Max(IEnumerable<Int64>)

Represents a collection of keys and values.

Max(IEnumerable<Nullable<Decimal>>)

Represents a collection of keys and values.

Max(IEnumerable<Nullable<Double>>)

Represents a collection of keys and values.

Max(IEnumerable<Nullable<Int32>>)

Represents a collection of keys and values.

Max(IEnumerable<Nullable<Int64>>)

Represents a collection of keys and values.

Max(IEnumerable<Nullable<Single>>)

Represents a collection of keys and values.

Max(IEnumerable<Single>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

Represents a collection of keys and values.

Max<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

Represents a collection of keys and values.

Max<TSource,TResult>(IEnumerable<TSource>, Func<TSource,TResult>)

Represents a collection of keys and values.

Min(IEnumerable<Decimal>)

Represents a collection of keys and values.

Min(IEnumerable<Double>)

Represents a collection of keys and values.

Min(IEnumerable<Int32>)

Represents a collection of keys and values.

Min(IEnumerable<Int64>)

Represents a collection of keys and values.

Min(IEnumerable<Nullable<Decimal>>)

Represents a collection of keys and values.

Min(IEnumerable<Nullable<Double>>)

Represents a collection of keys and values.

Min(IEnumerable<Nullable<Int32>>)

Represents a collection of keys and values.

Min(IEnumerable<Nullable<Int64>>)

Represents a collection of keys and values.

Min(IEnumerable<Nullable<Single>>)

Represents a collection of keys and values.

Min(IEnumerable<Single>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

Represents a collection of keys and values.

Min<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

Represents a collection of keys and values.

Min<TSource,TResult>(IEnumerable<TSource>, Func<TSource,TResult>)

Represents a collection of keys and values.

OfType<TResult>(IEnumerable)

Represents a collection of keys and values.

OrderBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

Represents a collection of keys and values.

OrderBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

Represents a collection of keys and values.

OrderByDescending<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

Represents a collection of keys and values.

OrderByDescending<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

Represents a collection of keys and values.

Prepend<TSource>(IEnumerable<TSource>, TSource)

Represents a collection of keys and values.

Reverse<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Select<TSource,TResult>(IEnumerable<TSource>, Func<TSource,TResult>)

Represents a collection of keys and values.

Select<TSource,TResult>(IEnumerable<TSource>, Func<TSource,Int32,TResult>)

Represents a collection of keys and values.

SelectMany<TSource,TResult>(IEnumerable<TSource>, Func<TSource,IEnumerable<TResult>>)

Represents a collection of keys and values.

SelectMany<TSource,TResult>(IEnumerable<TSource>, Func<TSource,Int32,IEnumerable<TResult>>)

Represents a collection of keys and values.

SelectMany<TSource,TCollection,TResult>(IEnumerable<TSource>, Func<TSource,IEnumerable<TCollection>>, Func<TSource,TCollection,TResult>)

Represents a collection of keys and values.

SelectMany<TSource,TCollection,TResult>(IEnumerable<TSource>, Func<TSource,Int32,IEnumerable<TCollection>>, Func<TSource,TCollection,TResult>)

Represents a collection of keys and values.

SequenceEqual<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

Represents a collection of keys and values.

SequenceEqual<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

Single<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

Single<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

SingleOrDefault<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

SingleOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

Skip<TSource>(IEnumerable<TSource>, Int32)

Represents a collection of keys and values.

SkipLast<TSource>(IEnumerable<TSource>, Int32)

Represents a collection of keys and values.

SkipWhile<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

SkipWhile<TSource>(IEnumerable<TSource>, Func<TSource,Int32,Boolean>)

Represents a collection of keys and values.

Sum(IEnumerable<Decimal>)

Represents a collection of keys and values.

Sum(IEnumerable<Double>)

Represents a collection of keys and values.

Sum(IEnumerable<Int32>)

Represents a collection of keys and values.

Sum(IEnumerable<Int64>)

Represents a collection of keys and values.

Sum(IEnumerable<Nullable<Decimal>>)

Represents a collection of keys and values.

Sum(IEnumerable<Nullable<Double>>)

Represents a collection of keys and values.

Sum(IEnumerable<Nullable<Int32>>)

Represents a collection of keys and values.

Sum(IEnumerable<Nullable<Int64>>)

Represents a collection of keys and values.

Sum(IEnumerable<Nullable<Single>>)

Represents a collection of keys and values.

Sum(IEnumerable<Single>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

Represents a collection of keys and values.

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

Represents a collection of keys and values.

Take<TSource>(IEnumerable<TSource>, Int32)

Represents a collection of keys and values.

TakeLast<TSource>(IEnumerable<TSource>, Int32)

Represents a collection of keys and values.

TakeWhile<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

TakeWhile<TSource>(IEnumerable<TSource>, Func<TSource,Int32,Boolean>)

Represents a collection of keys and values.

ToArray<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

Represents a collection of keys and values.

ToDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

ToDictionary<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>)

Represents a collection of keys and values.

ToDictionary<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

ToHashSet<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToHashSet<TSource>(IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

ToList<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

ToLookup<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

Represents a collection of keys and values.

ToLookup<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

ToLookup<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>)

Represents a collection of keys and values.

ToLookup<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

Represents a collection of keys and values.

Union<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

Represents a collection of keys and values.

Union<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

Represents a collection of keys and values.

Where<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

Represents a collection of keys and values.

Where<TSource>(IEnumerable<TSource>, Func<TSource,Int32,Boolean>)

Represents a collection of keys and values.

Zip<TFirst,TSecond,TResult>(IEnumerable<TFirst>, IEnumerable<TSecond>, Func<TFirst,TSecond,TResult>)

Represents a collection of keys and values.

AsParallel(IEnumerable)

Represents a collection of keys and values.

AsParallel<TSource>(IEnumerable<TSource>)

Represents a collection of keys and values.

AsQueryable(IEnumerable)

Represents a collection of keys and values.

AsQueryable<TElement>(IEnumerable<TElement>)

Represents a collection of keys and values.

Ancestors<T>(IEnumerable<T>)

Represents a collection of keys and values.

Ancestors<T>(IEnumerable<T>, XName)

Represents a collection of keys and values.

AncestorsAndSelf(IEnumerable<XElement>)

Represents a collection of keys and values.

AncestorsAndSelf(IEnumerable<XElement>, XName)

Represents a collection of keys and values.

Attributes(IEnumerable<XElement>)

Represents a collection of keys and values.

Attributes(IEnumerable<XElement>, XName)

Represents a collection of keys and values.

DescendantNodes<T>(IEnumerable<T>)

Represents a collection of keys and values.

DescendantNodesAndSelf(IEnumerable<XElement>)

Represents a collection of keys and values.

Descendants<T>(IEnumerable<T>)

Represents a collection of keys and values.

Descendants<T>(IEnumerable<T>, XName)

Represents a collection of keys and values.

DescendantsAndSelf(IEnumerable<XElement>)

Represents a collection of keys and values.

DescendantsAndSelf(IEnumerable<XElement>, XName)

Represents a collection of keys and values.

Elements<T>(IEnumerable<T>)

Represents a collection of keys and values.

Elements<T>(IEnumerable<T>, XName)

Represents a collection of keys and values.

InDocumentOrder<T>(IEnumerable<T>)

Represents a collection of keys and values.

Nodes<T>(IEnumerable<T>)

Represents a collection of keys and values.

Remove(IEnumerable<XAttribute>)

Represents a collection of keys and values.

Remove<T>(IEnumerable<T>)

Represents a collection of keys and values.

Thread Safety

A Dictionary<TKey,TValue> can support multiple readers concurrently, as long as the collection is not modified. Even so, enumerating through a collection is intrinsically not a thread-safe procedure. In the rare case where an enumeration contends with write accesses, the collection must be locked during the entire enumeration. To allow the collection to be accessed by multiple threads for reading and writing, you must implement your own synchronization.

For thread-safe alternatives, see the ConcurrentDictionary<TKey,TValue> class or ImmutableDictionary<TKey,TValue> class.

Public static (Shared in Visual Basic) members of this type are thread safe.