3 ms·
For example in a plugin system, I can say you must inherit from BasePlugin and in code I can enforce that, BasePlugin can then have some protected functions tha
by ehnto 3y ago
For example in a plugin system, I can say you must inherit from BasePlugin and in code I can enforce that, BasePlugin can then have some protected functions that I can disallow from being overridden.
It's good for frameworks and extensible systems where your code needs to guarantee certain things will happen when running third party code.