14.2. The Big Picture

Before getting into the details of the Power Collections, it will be helpful to step back and take a more conceptual view of the framework. Understanding this broader view will make it easier for you to determine the general roles that are played by each class in the library. This perspective should also provide you with a better idea for where and how you might want to introduce your own classes that extend the library.

The Power Collections library breaks down, logically, into base classes, containers, algorithms, delegates, and data structures. The sections that follow examine each of the constructs and explains, in more detail, the role each of these classes might play in your solutions.

In many respects, the classes that appear in the Power Collections library have their roots in classes that have been the staples of existing generic libraries. Specifically, you'll notice that the library borrows from concepts found in the Standard Template Library (STL) that is very popular among the C++ templates crowd. Naturally, with the constraints model employed by the .NET generics implementation, the library cannot offer a one-for-one mapping of the STL classes.

14.2.1. Base Classes

The Power Collections library introduces new types of data containers that offer alternative approaches to organizing and accessing data. The BCL's Collection<T> class, for example, implements an indexed collection that may be adequate as a base class. However, its implementation ...

Get Professional .NET 2.0 Generics now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.