StringDictionary.Keys Property

 

Gets a collection of keys in the StringDictionary.

Namespace:   System.Collections.Specialized
Assembly:  System (in System.dll)

abstract Keys : ICollection with get
override Keys : ICollection with get

Property Value

Type: System.Collections.ICollection

An ICollection that provides the keys in the StringDictionary.

The order of the keys in the ICollection is unspecified, but it is the same order as the associated values in the ICollection returned by the Values method.

The returned ICollection is not a static copy; instead, the ICollection refers back to the keys in the original StringDictionary. Therefore, changes to the StringDictionary continue to be reflected in the ICollection.

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

The following code example enumerates the elements of a StringDictionary.

No code example is currently available or this language may not be supported.

Universal Windows Platform
Available since 10
.NET Framework
Available since 1.1
Return to top
Show: