M
Martin
Hi all,
I'd like to find a .NET Collection in which I will be able to set many
keys for the same object.
For example, I would like to do something like that :
Dictionary<long, string> collection = new Dictionary<long, string>();
string myString = "Hello World";
collection.Add(0, myString);
collection.Add(myString.Lenght, myString);
Console.Write(collection.Count); // Result must be 1.
So, as you can see, I want to associate two keys to the same object.
Moreover, I don't want to add the object two times, but only one.
That's why I'd like to see collection.Count equal 1.
Someone could help me to achieve that?
Thanks for your help!
Martin
I'd like to find a .NET Collection in which I will be able to set many
keys for the same object.
For example, I would like to do something like that :
Dictionary<long, string> collection = new Dictionary<long, string>();
string myString = "Hello World";
collection.Add(0, myString);
collection.Add(myString.Lenght, myString);
Console.Write(collection.Count); // Result must be 1.
So, as you can see, I want to associate two keys to the same object.
Moreover, I don't want to add the object two times, but only one.
That's why I'd like to see collection.Count equal 1.
Someone could help me to achieve that?
Thanks for your help!
Martin