[]
Represents a generic collection of key/value pairs that provides notifications when items get added, removed, changed or when the whole list is refreshed.
public class ObservableDictionary<TKey, TValue> : ObservableCollection<ObservableKeyValuePair<TKey, TValue>>, IList<ObservableKeyValuePair<TKey, TValue>>, ICollection<ObservableKeyValuePair<TKey, TValue>>, IList, ICollection, IReadOnlyList<ObservableKeyValuePair<TKey, TValue>>, IReadOnlyCollection<ObservableKeyValuePair<TKey, TValue>>, IEnumerable<ObservableKeyValuePair<TKey, TValue>>, INotifyCollectionChanged, INotifyPropertyChanged, IDictionary<TKey, TValue>, ICollection<KeyValuePair<TKey, TValue>>, IEnumerable<KeyValuePair<TKey, TValue>>, IEnumerable
Name | Description |
---|---|
TKey | The type of keys in the dictionary. |
TValue | The type of values in the dictionary. |
Name | Description |
---|---|
ObservableDictionary() |
Name | Description |
---|---|
this[TKey] | Gets or sets the element with the specified key. |
Keys | Gets an ICollection<T> containing the keys of the ObservableDictionary<TKey, TValue>. |
Values | Gets an ICollection<T> containing the values in the ObservableDictionary<TKey, TValue>. |
Name | Description |
---|---|
Add(TKey, TValue) | Adds an element with the provided key and value to the ObservableDictionary<TKey, TValue>. |
ClearItems() | |
ContainsKey(TKey) | Determines whether the ObservableDictionary<TKey, TValue> contains an element with the specified key. |
GetEnumerator() | |
InsertItem(int, ObservableKeyValuePair<TKey, TValue>) | |
OnItemChanged(ItemChangedEventArgs<ObservableKeyValuePair<TKey, TValue>>) | Fires the ItemChanged event. |
Remove(TKey) | Removes the element with the specified key from the ObservableDictionary<TKey, TValue>. |
RemoveItem(int) | |
SetItem(int, ObservableKeyValuePair<TKey, TValue>) | |
TryGetValue(TKey, out TValue) | Gets the value associated with the specified key. |
Name | Description |
---|---|
ItemChanged | Occurs when a item value changes. |