Class Tools for Python
Convenience tools for working with Python classes.
class MyClass: def __init__(self, *args, **kwargs): pass # do whatever # subclass with presets MySubClass = argumented_subclass(MyClass, 'MySubClass', arg1='value', arg2=4)
class Thing: Red = ArgumentedSubclass(color='red') book = AutoProperty(has='pages') def __init__(self, color=None, has=None): self.color = color self.has = has Thing.Red # is a subclass of Thing and is 'red' Thing.Red.book # is an instance of Thing (and Thing.Red), is 'red' and has 'pages'
See the full documentation at http://classical.readthedocs.io/en/latest/
pip install classical
You may need to install [fielded,testing] extras to run tests
You may need to install [fielded,docs] extras to generate docs
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for classical-2.1.2-py3-none-any.whl