| |
| |
Preface | |
| |
| |
| |
Introduction | |
| |
| |
C++: An Evolving Language | |
| |
| |
Handling Complexity with Idioms | |
| |
| |
Objects for the Nineties | |
| |
| |
Design and Language | |
| |
| |
| |
Data Abstraction and Abstract Data Types | |
| |
| |
Classes | |
| |
| |
Object Inversion | |
| |
| |
Constructors and Destructors | |
| |
| |
Inline Functions | |
| |
| |
Initialization of Static Data Members | |
| |
| |
Static Member Functions | |
| |
| |
Scoping and const | |
| |
| |
Initialization Ordering of Global Objects, Constants, and Static Class Members | |
| |
| |
Enforcement of const for Class Object Member Functions | |
| |
| |
Pointers to Member Functions | |
| |
| |
Program Organization Conventions | |
| |
| |
| |
Concrete Data Types | |
| |
| |
The Orthodox Canonical Class Form | |
| |
| |
Scoping and Access Control | |
| |
| |
Overloading: Redefining the Semantics of Operators and Functions | |
| |
| |
Type Conversion | |
| |
| |
Reference Counting: Making Variables Use “Magic Memory | |
| |
| |
” Operators new and delete | |
| |
| |
Separating Initialization from Instantiation | |
| |
| |
| |
Inheritance | |
| |
| |
Simple Inheritance | |
| |
| |
Scoping and Access Control | |
| |
| |
Constructors and Destructors | |
| |
| |
Class Pointer Conversion | |
| |
| |
Type Selector Fields | |
| |
| |
| |
Object-Oriented Programming | |
| |
| |
C++ Run-Time Type Support: Virtual Functions | |
| |
| |
Destructor Interaction and Virtual Destructors | |
| |
| |
Virtual Functions and Scoping | |
| |
| |
Pure Virtual Functions and Abstract Base Classes | |
| |
| |
Envelope and Letter Classes | |
| |
| |
Functors: Functions as Objects | |
| |
| |
Multiple Inheritance | |
| |
| |
The Inheritance Canonical Form | |
| |
| |
| |
Object-Oriented Design | |
| |
| |
Types and Classes | |
| |
| |
The Activities of Object-Oriented Design | |
| |
| |
Object-Oriented Analysis and Domain Analysis | |
| |
| |
Object and Class Relationships | |
| |
| |
Subtyping, Inheritance and Forwarding | |
| |
| |
Rules of Thumb for Subtyping, Inheritance, and Independence | |
| |
| |
| |
Reuse and Objects | |
| |
| |
All Analogies Break Down Somewhere | |
| |
| |
Design Reuse | |
| |
| |
Four Code Reuse Mechanisms | |
| |
| |
Parameterized Types, or Templates | |
| |
| |
Private Inheritance: Does Inheritance Support Reuse? | |
| |
| |
Storage Reuse | |
| |
| |
Interface Reuse: Variants | |
| |
| |
Reuse, Inheritance, and Forwarding | |
| |
| |
Architectural Alternatives for Source Reuse | |
| |
| |
Generalizations on Reuse and Objects | |
| |
| |
| |
Programming with Exemplars in C++ | |
| |
| |
An Example: Employee Exemplars | |
| |
| |
Exemplars and Generic Constructors: The Exemplar Community Idiom | |
| |
| |
Autonomous Generic Constructors | |
| |
| |
Abstract Base Exemplars | |
| |
| |
Toward a Frame Exemplar Idiom | |
| |
| |
A Word About Notation | |
| |
| |
Exemplars and Program Administration | |
| |
| |
| |
Emulating Symbolic Language Styles in C++ | |
| |
| |
Incremental C++ Development | |
| |
| |
Symbolic Canonical Form | |
| |
| |
An Example: A General Collection Class | |
| |
| |
Code and Idioms To Support Incremental Loading | |
| |
| |
Garbage Collection | |
| |
| |
Primitive Type Encapsulation | |
| |
| |
Multi-Methods under the Symbolic Idiom | |
| |
| |
| |
Dynamic Multiple Inheritance | |
| |
| |
An Example: A Multi-Technology Window System | |
| |
| |
Caveats | |
| |
| |
| |
Systemic Issues | |
| |
| |
Static System Design | |
| |
| |
Dynamic System Design | |
| |
| |
Appendix A: C in a C++ Environment | |
| |
| |
Function Calls | |
| |
| |
Function Parameters | |
| |
| |
Function Prototypes | |
| |
| |
Call-by-Reference Parameters | |
| |
| |
Variable Number of Parameters | |
| |
| |
Function Pointers | |
| |
| |
The const Type Modifier | |
| |
| |
Interfacing with C Code | |
| |
| |
| |
Shapes Program: C++ Code | |
| |
| |
| |
Reference Return Values from Operators | |
| |
| |
| |
Why Bitwise Copy Doesn't Work | |
| |
| |
Why Member-by-Member Copy Isn& | |