What is the use of ABCMeta's register method?
https://docs.python.org/3/library/abc.html
It seems that if I have an abstract base class ABC, say, Animal, I can register a subclass of it using register:
from abc import ABC
class Animal(ABC):
pass
@Animal.register
class Dog:
pass
But isn't this the very same as just defining the subclass as inheriting from the base class?
class Dog(Animal): # same as wrapping with Animal.register decorator?
pass
In other words, is it just a way to kind of dynamically define inheritance? Or am I missing some things that this method does?