Package Pyblosxom :: Module _logging
[show private | hide private]
[frames | no frames]

Module Pyblosxom._logging

Emulates part of the Python2.3 logging module. Note: This will probably not work with Python < 2.2.
Classes
FileHandler A stripped down version of the logging.FileHandler class.
Filterer A stripped down version of the logging.Filterer class.
Formatter A stripped down version of the logging.Formatter class.
Logger A stripped down version of the logging.Logger class.
LogRecord A stripped down version of the logging.LogRecord class.
StreamHandler A stripped down version of the logging.StreamHandler class.

Function Summary
  __populate_levels()
Fills in the _levels and _level_names dictionaries.
  dump(msg, *args)
Utility function to log stuff while working on the _logging module.
str getLevelName(level)
Return the textual representation of logging level 'level'.
  getLogger(log_name)
Creates and returns a logging channel.
  shutdown()
Close logfiles and clear the logger-registry.

Variable Summary
str _devlogfile = '/tmp/dev-log.log'
dict _handlers = {}
dict _level_names = {0: 'NOTSET', 40: 'ERROR', 10: 'DEBUG', 5...
dict _levels = {'INFO': 20, 'NOTSET': 0, 'WARNING': 30, 'WARN...
NoneType _log = None                                                                  
dict _logger_registry = {}
list _names = ['FATAL', 'CRITICAL', 'ERROR', 'WARN', 'WARNING...
str _srcfile = '/home/willg/pyblosxom/Pyblosxom/_logging.py'...
float _startTime = 1139370235.469486                                                     
int CRITICAL = 50                                                                    
int DEBUG = 10                                                                    
int ERROR = 40                                                                    
int FATAL = 50                                                                    
int INFO = 20                                                                    
int NOTSET = 0                                                                     
int WARN = 30                                                                    
int WARNING = 30                                                                    

Function Details

__populate_levels()

Fills in the _levels and _level_names dictionaries.

dump(msg, *args)

Utility function to log stuff while working on the _logging module.

getLevelName(level)

Return the textual representation of logging level 'level'.
Parameters:
level - Numeric representation of a logging level
           (type=int)
Returns:
Texutal representation of the logging level
           (type=str)

getLogger(log_name=None)

Creates and returns a logging channel. Registers the created logger in the logger-registry for further reference.

shutdown()

Close logfiles and clear the logger-registry.

Variable Details

_devlogfile

Type:
str
Value:
'/tmp/dev-log.log'                                                     

_handlers

Type:
dict
Value:
{}                                                                     

_level_names

Type:
dict
Value:
{0: 'NOTSET',
 10: 'DEBUG',
 20: 'INFO',
 30: 'WARNING',
 40: 'ERROR',
 50: 'CRITICAL'}                                                       

_levels

Type:
dict
Value:
{'CRITICAL': 50,
 'DEBUG': 10,
 'ERROR': 40,
 'FATAL': 50,
 'INFO': 20,
 'NOTSET': 0,
 'WARN': 30,
 'WARNING': 30}                                                        

_log

Type:
NoneType
Value:
None                                                                  

_logger_registry

Type:
dict
Value:
{}                                                                     

_names

Type:
list
Value:
['FATAL', 'CRITICAL', 'ERROR', 'WARN', 'WARNING', 'INFO', 'DEBUG', 'NO\
TSET']                                                                 

_srcfile

Type:
str
Value:
'/home/willg/pyblosxom/Pyblosxom/_logging.py'                          

_startTime

Type:
float
Value:
1139370235.469486                                                     

CRITICAL

Type:
int
Value:
50                                                                    

DEBUG

Type:
int
Value:
10                                                                    

ERROR

Type:
int
Value:
40                                                                    

FATAL

Type:
int
Value:
50                                                                    

INFO

Type:
int
Value:
20                                                                    

NOTSET

Type:
int
Value:
0                                                                     

WARN

Type:
int
Value:
30                                                                    

WARNING

Type:
int
Value:
30                                                                    

Generated by Epydoc 2.1 on Tue Feb 7 21:43:58 2006 http://epydoc.sf.net