src/NetStandard/Collections/Collections/src/Specialized/OrderedDictionary.cs
/// <summary>
/// Sets the value at the index specified.
/// </summary>
/// <param name="index">The index of the value desired</param>
/// <param name="value">The value to set</param>
/// <exception cref="ArgumentOutOfRangeException">
/// Thrown when the index specified does not refer to a KeyValuePair in this object
/// </exception>
Sets the value at the index specified.
Sets the value at the index specified .
public void SetItem(int index, [AllowNull] V value)
        {
            if (index < 0 || index >= keyedCollection.Count) {
                throw new ArgumentException("The index is outside the bounds of the dictionary: " + index);
            }
            keyedCollection[index] = new KeyValuePair<K, V>(keyedCollection[index].Key, value!);
        }
public void SetItem ( int index , [ AllowNull ] V value ) { if ( index < 0 || index >= keyedCollection . Count ) { throw new ArgumentException ( " " + index ) ; } keyedCollection [ index ] = new KeyValuePair < K , V > ( keyedCollection [ index ] . Key , value ! ) ; }
Sets the value at the index specified.
Sets the value at the index specified .
Thrown when the index specified does not refer to a KeyValuePair in this object
Thrown when the index specified does not refer to a KeyValuePair in this object
index
int
The index of the value desired
The index of the value desired
V
[AllowNull]
value
The value to set
The value to set