Skip to main content

getclass(object) function - get object class

Project description


$ [sudo] pip install getclass


function __doc__
getclass.getclass(obj) return instance/method/property/classmethod/staticmethod class


>>> from getclass import getclass

>>> class CLS:
    def method(self): pass

    def property(self): pass

    def classmethod(cls,x): pass

    def staticmethod(x): pass

    def __str__(self): pass

>>> getclass(CLS())
<class __main__.CLS>

>>> getclass(CLS.method)
<class __main__.CLS>

>>> getclass(
<class __main__.CLS>

>>> getclass(CLS.classmethod)
<class __main__.CLS>

>>> getclass(CLS.staticmethod)
<class __main__.CLS>

readme-md - generator

Project details

Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
getclass-2018.12.11-py2.py3-none-any.whl (2.6 kB) Copy SHA256 hash SHA256 Wheel py2.py3
getclass-2018.12.11.tar.gz (2.2 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page