I have the following functions:
public static V AddIfNotPresent<K, V>( this Dictionary<K, V> store, K key ) where V : new() public static V AddIfNotPresent<K, V>( this Dictionary<K, V> store, K key )
First, is it possible to overload functions this way?
If overloading is not possible, I can be more specific with my functions and tools:
public static string Foo<K, string>( this Dictionary<K, string> store, K key )
Like a little History I have a dictionary with string values, and I would live a sequential extension of the "Foo" Dictionary to allow me to add new () objects or an empty string (depending on the situation).
source share