Geeks With Blogs
Paul's Petrov Whiteboard [BizTalk, Enterprise Application Integration, Business Process Automation, SOA, .NET] November 2007 Entries
Generic custom configuration elements collection based on ConfigurationElementCollection
Simple trick that saves me some time and coding when writing custom configuration objects is to define generic collection for them. Let's say I created several custom configuration elements derived from my CustomConfigElementBase which in turn inherits from System.Configuration.Config... Instead of defining strongly typed collections for each type I can simply define class: public class GenericConfigElementCollect... : ConfigurationElementCollection where T : CustomConfigElementBase, ......

Posted On Tuesday, November 13, 2007 1:32 PM

Copyright © Paul Petrov | Powered by: