Early Preview
This is currently very much a preview. Please feel free to try things out,
but don't be upset if anything is not yet working. Feedback is welcome over on our
GitHub Dicussions page.
class System.​Collections.​Specialized.​StringDictionary
Assembly: System.Collections.Specialized
Inheritance: object → StringDictionary
Implemented Interfaces
Implements a hash table with the key and the value strongly typed to be strings rather than objects.
Properties
public
int
Count
Gets the number of key/value pairs in the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
public
bool
IsSynchronized
Gets a value indicating whether access to the <see cref="T:System.Collections.Specialized.StringDictionary" /> is synchronized (thread safe).
public
string
Item
public
ICollection
Keys
Gets a collection of keys in the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
public
object
SyncRoot
Gets an object that can be used to synchronize access to the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
public
ICollection
Values
Gets a collection of values in the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
Methods
public
void
Add​(string key,
string value)
Adds an entry with the specified key and value into the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
key
The key of the entry to add.
value
The value of the entry to add. The value can be <see langword="null" /> .
public
void
Clear​()
Removes all entries from the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
public
bool
ContainsKey​(string key)
Determines if the <see cref="T:System.Collections.Specialized.StringDictionary" /> contains a specific key.
Returns <see langword="true" /> if the <see cref="T:System.Collections.Specialized.StringDictionary" /> contains an entry with the specified key; otherwise, <see langword="false" /> .
key
The key to locate in the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
public
bool
ContainsValue​(string value)
Determines if the <see cref="T:System.Collections.Specialized.StringDictionary" /> contains a specific value.
Returns <see langword="true" /> if the <see cref="T:System.Collections.Specialized.StringDictionary" /> contains an element with the specified value; otherwise, <see langword="false" /> .
value
The value to locate in the <see cref="T:System.Collections.Specialized.StringDictionary" /> . The value can be <see langword="null" /> .
public
void
CopyTo​(Array array,
int index)
Copies the string dictionary values to a one-dimensional <see cref="T:System.Array" /> instance at the specified index.
array
The one-dimensional <see cref="T:System.Array" /> that is the destination of the values copied from the <see cref="T:System.Collections.Specialized.StringDictionary" /> .
index
The index in the array where copying begins.
public
IEnumerator
GetEnumerator​()
Returns an enumerator that iterates through the string dictionary.
Returns An <see cref="T:System.Collections.IEnumerator" /> that iterates through the string dictionary.
public
void
Remove​(string key)
Removes the entry with the specified key from the string dictionary.
key
The key of the entry to remove.
public
bool
Equals​(object obj)
Inherited from object
protected
void
Finalize​()
Inherited from object
public
int
GetHashCode​()
Inherited from object
protected
object
MemberwiseClone​()
Inherited from object
public
string
ToString​()
Inherited from object