Package mvpa :: Package base :: Module verbosity :: Class SetLogger
[hide private]
[frames] | no frames]

Class SetLogger

source code


Logger which prints based on defined sets identified by Id.
Instance Methods [hide private]
 
__init__(self, register=None, active=None, printsetid=True, *args, **kwargs)
Initialize the logger with a set of handlers to use for output
source code
 
_setActive(self, active)
Set active logging set
source code
 
_setPrintsetid(self, printsetid)
Either to print set Id at each line
source code
 
__call__(self, setid, msg, *args, **kwargs)
Write msg
source code
 
register(self, setid, description)
"Register" a new setid with a given description for easy finding
source code
 
setActiveFromString(self, value)
Given a string listing registered(?) setids, make then active
source code
 
print_registered(self, detailed=True) source code

Inherited from Logger: __del__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  printsetid = property(fget= lambda self: self.__printsetid, fs...
  active = property(fget= lambda self: self.__active, fset= _set...
  registered = property(fget= lambda self: self.__registered)

Inherited from Logger: handlers, lfprev

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, register=None, active=None, printsetid=True, *args, **kwargs)
(Constructor)

source code 

Initialize the logger with a set of handlers to use for output

Each hanlder must have write() method implemented

Overrides: object.__init__
(inherited documentation)

__call__(self, setid, msg, *args, **kwargs)
(Call operator)

source code 

Write msg

It appends a newline since most commonly each call is a separate message

Overrides: Logger.__call__

Class Variable Details [hide private]

printsetid

Value:
property(fget= lambda self: self.__printsetid, fset= _setPrintsetid)

active

Value:
property(fget= lambda self: self.__active, fset= _setActive)