Skip to main content

just add @logMethod and @logClass to add log files for your methods

Project description

[license]

llogpy

what is llogpy ?

  • llogpy is a open source logging modules developed for people who want to log certain methods in a class or a function.
  • all you have to do is decorate a function with @logMethod. If you want to log entire class i mean all methods in a class just decorate with @logClass
  • please refer to examples on how to use llogpy
  • Note Logging methods dosent works on static function in class
Screen Shot 2019-11-06 at 8 35 47 AM

Installation

pip install llogpy

Usage

from llogpy.llogpy import logMethod,logClass


class A(object):
    def __init__(self):
        pass

    @logMethod
    def method(self):
        print(" I am a method ")

    @logMethod
    def clsmethod(cls):
        print(" i am a class method ")


if __name__ == "__main__":
    obj = A()
    obj.method()
    obj.clsmethod()

Example 2

from llogpy.llogpy import logMethod,logClass

@logClass
class A(object):
    def __init__(self):
        pass

    def method(self):
        print(" I am a method ")


    def clsmethod(cls):
        print(" i am a class method ")


if __name__ == "__main__":
    obj = A()
    obj.method()
    obj.clsmethod()

Authors

Soumil Nitin Shah

Bachelor in Electronic Engineering | Masters in Electrical Engineering | Master in Computer Engineering |

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Project details


Release history Release notifications

This version

3.0.0

Download files

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

Files for llogpy, version 3.0.0
Filename, size File type Python version Upload date Hashes
Filename, size llogpy-3.0.0-py3-none-any.whl (15.5 kB) File type Wheel Python version py3 Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page