SNN2.src.io.logger module

logger Module

Use this module in order to handle the logging operations

class SNN2.src.io.logger.LogHandler(file, level)

Bases: object

LogHandler. Class used in order to handle the log saving process

CRITICAL = 50
DEBUG = 10
ERROR = 40
INFO = 20
WARNING = 30
classmethod findLL(level: int) int

findLL. Given an integer it returns the correct class level to asociate with it

Parameters:

level (int) – level

Return type:

int

write(obj: str, message: str, level: int = 20) None

write. Write to the file a specific message. It’s mandatory to define the object of the message. Usually the object corresponds to the class that has called the method self.__class__.__name__.

Parameters:
  • obj (str) – obj of the message

  • message (str) – actual message

  • level (int) – level to register the message

Return type:

None