jargon

Design patterns·Objects, messages and the principles

the subclass replaces the parent's version of a method, and every existing caller silently starts getting the new one.

Method overriding

Also calledoverride, overriding

Providing a subclass implementation of a method the parent already defines, so calls through the parent's type reach the child's version. It is the primary extension point of inheritance and the primary way inheritance goes wrong, because the parent's other methods may call the one you replaced and assume the old behaviour. This is what the Liskov substitution principle is about, and what makes overriding a stronger commitment than it looks.

Commonly confused with