Which of the .NET 3.5 namespaces is the most underutilized yet contains some of the classes and methods considered "must-know" for every .NET developer?
Some developers using .NET 3.5 are, unfortunately, still not familiar with:
- System.Collections.Generic. Developers should not be intimidated by generics at all. They are fun, easy, powerful, and there is a lot of important things based on them. They are a basic building block of more and more important things. There is a junior developer at work who is wondering what to learn, and I'm begging her to check out generics. Generic collections are the best, easiest way to get experience with generics.
- System.Xml.Linq. The new "X" objects, (XDocument, XElement, etc.) make XML a lot easier. This provides a lot of power, even if you're not using them for linq. But they are also a great way to start using linq. And folks, linq is not an advanced specialty technique; it will soon be expected that you can use it. But it's not hard! -And if you're in a VB shop, you can leverage this ability with xml literals. (if you're using vb and not xml literals, you're giving up the only substantial advantage vb has over c#.)
Personally, I feel that System.Threading is underused and misunderstood by many developers. Most modern programming really should have some multi-threaded code, but this is often avoided due to the added complexity.
That being said, there are nuggets in common namespaces throughout the framework that are often underutilized, like some of the classes in System.IO (ie: using string concatenation instead of the Path class methods is something I see far too often).
I find that System.Collections.Specialized has some useful and less well known classes:
- OrderedDictionary
- HybridDictionary
- BitVector
System.Diagnostics is another treasure trove with classes like:
- Debug
- Debugger
- Trace
- StackTrace
- Process
- FileVersionInfo
Got to be System.Linq.Expressions for me. The power of expression trees is overlooked by a lot of developers..
A comment to the top answer says "I see people use List all over the place when they'd be better off inheriting from Collection and creating their own wrapper" (by "flesh"). Can someone dwell on this some more? Why should I not prefer using List?
Thanks.