This project has moved. For the latest updates, please go here.

PolymorphicConfigurationElementCollection in CSD?


There is a class in the Microsoft Enterprise Library called PolymorphicConfigurationElementCollection<T> which allows a configuration element to contain a collection of config elements of polymorphic type. This turned out to be fairly useful to me, but using it meant that I had to move my configuration section and configuration element classes away from CSD. It would be great if CSD offered a similar capability.


andym1978 wrote Sep 10, 2014 at 7:56 PM

I briefly looked at this class and it is quite interesting. I'm going to learn more about it and report back asap. Thanks for letting us know!

andym1978 wrote Sep 10, 2014 at 8:00 PM

Some reference links below:

Stackoverflow question

MSDN page

iLMaX wrote Sep 16, 2014 at 9:57 PM

Interesting one! Some thoughts:

What should be the discriminator? Should we list all collection supported types via UI? Should we use a base abstract type and all derived are accepted?

The implementation of the collection seems quite easy.

wrote Jan 14, 2015 at 3:26 PM