Mini Shell

Direktori : /opt/imh-python/lib/python3.9/site-packages/ldap/
Upload File :
Current File : //opt/imh-python/lib/python3.9/site-packages/ldap/logger.py

# -*- coding: utf-8 -*-
"""
Helper class for using logging as trace file object
"""

import logging

class logging_file_class(object):

    def __init__(self, logging_level):
        self._logging_level = logging_level

    def write(self, msg):
        logging.log(self._logging_level, msg[:-1])

    def flush(self):
        return

logging_file_obj = logging_file_class(logging.DEBUG)

Zerion Mini Shell 1.0