September 2002
Intermediate to advanced
496 pages
10h
English
C# supports a single inheritance model. Thus a class may derive from a single base class, and not from more than one. (In fact, as we saw earlier in the appendix, every class in C# ultimately derives from the root class System.Object. In C# we may use the alias object for this root class.) This single inheritance model is simple and avoids the complexities and ambiguities associated with multiple inheritance in C++. Although a C# class can inherit only from a single base class, it may inherit from several interfaces, a topic we will discuss later.
With inheritance, you factor the abstractions in your object model and put the more reusable abstractions in a high-level base class. You can add or change ...
Read now
Unlock full access