Rosetta  2020.37
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Public Attributes | List of all members
pyrosetta.distributed.utility.log.LoggingContext Class Reference
Inheritance diagram for pyrosetta.distributed.utility.log.LoggingContext:
Inheritance graph
[legend]

Public Member Functions

def __init__
 
def __enter__
 
def __exit__
 

Public Attributes

 logger
 
 level
 
 handler
 
 close
 
 old_level
 

Detailed Description

Context handler to modify logging configuration with context.

Example:
    with LoggingContext(rosetta.logger, level=logging.WARNING):
        #...very chatty functions...

    # Back to normal logging

Constructor & Destructor Documentation

def pyrosetta.distributed.utility.log.LoggingContext.__init__ (   self,
  logger,
  level = None,
  handler = None,
  close = True 
)

Member Function Documentation

def pyrosetta.distributed.utility.log.LoggingContext.__enter__ (   self)
def pyrosetta.distributed.utility.log.LoggingContext.__exit__ (   self,
  et,
  ev,
  tb 
)

Member Data Documentation

pyrosetta.distributed.utility.log.LoggingContext.close
pyrosetta.distributed.utility.log.LoggingContext.handler
pyrosetta.distributed.utility.log.LoggingContext.level
pyrosetta.distributed.utility.log.LoggingContext.logger
pyrosetta.distributed.utility.log.LoggingContext.old_level

The documentation for this class was generated from the following file: