Manage a group of associated data using collections
Microsoft .NET Framework, ASP.NET, Visual C# (CSharp, C Sharp, C-Sharp) Developer Training, Visual Studio
Exam 70-536 Preparation Guide: Manage a group of associated data in a .NET Framework application by using collections. (Refer System.Collections namespace)
|
Contents |
[edit]
Introduction
Collections are an essential part of any modern programming language.
Collection Classes have the following properties:
- Collection classes are defined as part of the
System.Collectionsnamespace.
- Most collection classes derive from the interfaces
ICollection,IComparer,IEnumerable,IList,IDictionary, andIDictionaryEnumerator.
[edit]
Type Safety
Most of the standard collections are not type safe.
Therefore, all objects must be cast to their appropriate type when using them from with the collection. Also, in order to store value types, they must perform boxing/unboxing operations.
[edit]
Generics
Because these collections are untyped, you should use generic collections unless backwards compatibility is needed.
Using generic collection classes provides increased type-safety and in some cases can provide better performance, especially when storing value types.
[edit]
MSDN References
|

