>I only think of generics when I go to CVS.
>Now I'm guilt-ridden, having delivered hundreds of thousands of lines of .NET code without a single interface or generic.
>What have I been missing?
Speaking of CVS, there are a million of them in the area where we live now.
I've got a slew of examples (some of them from prior CODE articles). I'll dig them up and post a few of the better ones.
Where I've used them heavily:
- reporting applications
- reusable data binding libraries
- in conjunction with WCF code
- policy document applications
I'll bet you've probably used at least a few instances of generics without realizing. Custom collections/lists are sort of tied to generics. So in SSRS, when you do something like this:
List<ReportParameter> ParmList = new List<ReportParameter>();
ParmList.Add( new ReportParameter("AccountID",101));
ParmList.Add( new ReportParameter("ProductID",202));
ReportObjectToRun.SetParameters( ParmList);
...you're using one of the basics of generics. Basically, you're saying, "create a list of type ReportParameter", where ReportParameter comes from the SSRS webforms namespace. (That's a very simple example)