groundwork
groundwork copied to clipboard
Use AbtractBaseClass for Basic Patterns
The GwBasePattern should inherit from ABC and provide some abstract methods, which needs to be implemented by child classes/patterns/plugins. Like activate(), deactivate().
See https://docs.python.org/3/library/abc.html and https://julien.danjou.info/blog/2013/guide-python-static-class-abstract-methods
Another approach would be to use metaclasses and check the existence of class-members during class creation by customizing __new__