Inheritance (OOP) is when an
object or
class is based on another object (
prototypal inheritance) or class (
class-based inheritance), using the same implementation (inheriting from an object or class) specifying implementation to maintain the same behavior (realizing an interface; inheriting behavior). It is a mechanism for
code reuse and to allow independent extensions of the original software via public classes and interfaces. The relationships of objects or classes through inheritance give rise to a
hierarchy. Inheritance was invented in 1967 for
Simula.