IDictionary(TKey, TValue).Keys Property
.NET Framework Class Library
Dictionary<(Of <(TKey, TValue>)>)..::.IDictionary<(Of <(TKey, TValue>)>)..::.Keys Property

Gets an ICollection<(Of <(T>)>) containing the keys of the IDictionary<(Of <(TKey, TValue>)>).

Namespace:  System.Collections.Generic
Assembly:  mscorlib (in mscorlib.dll)

Visual Basic (Declaration)
Private ReadOnly Property Keys As ICollection(Of TKey)
    Implements IDictionary(Of TKey, TValue).Keys
Visual Basic (Usage)
Dim instance As Dictionary
Dim value As ICollection(Of TKey)

value = CType(instance, IDictionary(Of TKey, TValue)).Keys
C#
ICollection<TKey> IDictionary<TKey, TValue>.Keys { get; }
Visual C++
private:
virtual property ICollection<TKey>^ Keys {
    ICollection<TKey>^ get () sealed = IDictionary<TKey, TValue>::Keys::get;
}
J#
J# supports the use of explicit interface implementations, but not the declaration of new ones.
JScript
JScript does not support explicit interface implementations.

Property Value

Type: System.Collections.Generic..::.ICollection<(Of <(TKey>)>)

An ICollection<(Of <(T>)>) of type TKey containing the keys of the IDictionary<(Of <(TKey, TValue>)>).

Implements

IDictionary<(Of <(TKey, TValue>)>)..::.Keys

The order of the keys in the returned ICollection<(Of <(T>)>) is unspecified, but it is guaranteed to be the same order as the corresponding values in the ICollection<(Of <(T>)>) returned by the Values property.

Getting the value of this property is an O(1) operation.

Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98, Windows CE, Windows Mobile for Smartphone, Windows Mobile for Pocket PC, Xbox 360

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0 SP1, 3.0, 2.0 SP1, 2.0

.NET Compact Framework

Supported in: 3.5, 2.0

XNA Framework

Supported in: 1.0
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
Page view tracker