Skip to main content

A decorator used to inherit method documentation from parent classes.

Project description

A decorator used to inherit method documentation from parent classes.

Badges

https://img.shields.io/travis/kavdev/python-doc-inherit/master.svg?style=flat-square https://img.shields.io/codecov/c/github/kavdev/python-doc-inherit/master.svg?style=flat-square https://img.shields.io/requires/github/kavdev/python-doc-inherit.svg?style=flat-square https://img.shields.io/codacy/75dbe2685efe47c3aa203a53154c9e7e.svg?style=flat-square https://img.shields.io/pypi/v/python-doc-inherit.svg?style=flat-square https://img.shields.io/pypi/dw/python-doc-inherit.svg?style=flat-square https://img.shields.io/github/issues/kavdev/python-doc-inherit.svg?style=flat-square https://img.shields.io/github/license/kavdev/python-doc-inherit.svg?style=flat-square

Usage

Install python-doc-inherit:

pip install python-doc-inherit

Put it to use:

from doc_inherit import method_doc_inherit

class Foo(object):

    def foo(self):
        """Frobber"""

        pass

class Bar(Foo):

    @method_doc_inherit
    def foo(self):
        pass

Now, Bar.foo.__doc__ == Bar().foo.__doc__ == Foo.foo.__doc__ == "Frobber"

Running the Tests

pip install -r requirements/test.txt
./runtests.py

Changes

0.1.1 (2016-06-18)

  • small fixes

0.1.0 (2016-06-18)

  • Initial release

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python-doc-inherit-0.1.1.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

python_doc_inherit-0.1.1-py2.py3-none-any.whl (4.6 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file python-doc-inherit-0.1.1.tar.gz.

File metadata

File hashes

Hashes for python-doc-inherit-0.1.1.tar.gz
Algorithm Hash digest
SHA256 30a5b4f9d219a75e6396f53d331b454c64b5394168e38bf41b9a1c87e098b5dc
MD5 80333e151501eb066b0679ac1dee4938
BLAKE2b-256 30e5220b5bc847d65418fe3d28db75ee681c7d450d74fa60698fa5c379865c33

See more details on using hashes here.

File details

Details for the file python_doc_inherit-0.1.1-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for python_doc_inherit-0.1.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 71b4039a7009cdfec5f23fbb7d70a6e95f32477bcf9e9d02e5468b034bfc16db
MD5 c0902bf177f26d0b4b796c7e5ed40c0e
BLAKE2b-256 d3ea8411258c98baa8a63bc3b24e2925fa3406dd07ab0000504ae0e20ec38bab

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page