C++ General: What are the principles of Object-Oriented Design?
Q: What are the OOD principles and paradigms?
A: Here is a comprehensive list of the main OOD principles with links to articles.
Open Close Principle (OCP)
Description Software entities should be open for extension, but closed for modification. B. Meyer, 1988 / quoted by Robert Martin, 1996 No significant program can be 100% closed. R. Martin, The Open-Closed Principle, 1996
Make all object-data private! No Global Variables!
Description Inheritance should ensure that any property proved about super-type objects also holds for subtype objects. Barbara Liskov, 1987 Functions that use pointers or references to base classes must be able to use objects of derived classes without knowing it. Robert Martin, 1996
It is illegal for a derived class, to override a base-class method with a method that does nothing.
Description I. High-level modules should not depend on low-level modules. Both should depend on abstractions.
II. Abstractions should not depend on details. Details should depend on abstractions. R. Martin, 1996
Description Any object receiving a message in a given method must be one of a restricted set of objects. Strict Form: Every supplier class or object to a method must be a preferred supplier. Minimization Form: Minimize the number of acquaintance classes / objects of each method. Lieberherr and Holland