Closed kowsari closed 12 years ago
Hello Koussari,
The problem with adding a Tag to the base element class is that everyone will end up paying the memory price for this new field. I tried to keep the Element class as lightweight as possible for that reason.
What you can do, if you need to associate data in this way, is to keep a Dictionary with a mapping frmo your elements to your data.
It would be nice to have a Tag field in the Element class so that we can associate user defined data (such as database IDs) to each Entry. You also need to add a function to Element class to traverse the elements and find the object with the given tag.