AllowNullDictionaryTKey, TValueRemove Method

Removes the value with the specified key from the AllowNullDictionaryTKey, TValue.

Definition

Namespace: KGySoft.Collections
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
C#
public bool Remove(
	TKey key
)

Parameters

key  TKey
Key of the item to remove.

Return Value

Boolean
if the element is successfully removed; otherwise, . This method also returns if key was not found in the dictionary.

Implements

IDictionaryTKey, TValueRemove(TKey)

Remarks

If the AllowNullDictionaryTKey, TValue does not contain an element with the specified key, the dictionary remains unchanged. No exception is thrown.

This method approaches an O(1) operation.

See Also