In Chapter 3, we focused on some of the key aspects of the .NET Framework and how to leverage them from C#. However, access to these capabilities isn’t limited to C#.
Almost all the capabilities of the .NET Framework are exposed via a set of managed types known as the Base Class Library (BCL). Because these types are CLS-compliant, they are accessible from almost any .NET language. BCL types are grouped logically by namespace and are exported from a set of assemblies (DLLs) that are part of the .NET platform. Using these types in a C# application requires you to reference the appropriate assembly when compiling (see Appendix F).
In order to work effectively in C# on the .NET platform, it is important to understand the general capabilities in the predefined class library. However, the library is far too large to cover completely in this book, as it encompasses approximately 4,500 types grouped into 120 namespaces and exported from 40 different assemblies.
Instead, in this chapter, we give an overview of the entire BCL (broken down by logical area) and provide references to relevant types and namespaces so that you can explore their details in the .NET Framework SDK on your own.
The specific types and namespaces mentioned in this overview are based on beta 1 of the .NET Framework and may change in future betas and the released version.
Useful tools for exploring the BCL include the .NET Framework SDK documentation, the WinCV.exe class browser, and the ILAsm.exe disassembler (see Chapter 5)
core types are contained in the
namespace. This namespace is the heart of
the BCL and contains classes, interfaces, and attributes that all
other types depend on. The root of the BCL is the type
which all other .NET types derive. Other fundamental types are
(base type for structs),
type for enums),
(used to convert between base types),
(base type for all exceptions), and the
boxed versions of the predefined value types. Interfaces that are
used throughout the BCL such as
are defined here
(see Section 3.3 in Chapter 3). Extended types such as
are also available.
Other classes include support for single and multicast
delegates (see Section 2.13 in Chapter 2), basic math operations (see Section 3.2 in Chapter 3), attributes (see Section 2.16 in Chapter 2), and exception handling (see Section 2.15 in Chapter 2).
For more string information, see the