Say I have a base abstract class called Animal , which has a virtual method called Move .
I am creating a child class called Mammal that inherits from Animal and defines a Move method.
Then I create a child class Mammal called Rabbit .
Here's the thing:
I do not want Rabbit be able to override the implementation of Move that is already defined by Mammal (child classes of Mammal should not change the definition of Move that Mammal defined).
Since Rabbit inherits from Mammal , is it possible to βactivateβ the Move method in the Mammal class to prevent classes from inheriting from overriding the method definition in Mammal ?
source share