| # Gaudi Framework, version v21r6 |

Home |  | Generated: 11 Nov 2009

# ProcessJobOptions::LogFilter Class Reference

List of all members.

## Detailed Description

Definition at line 19 of file ProcessJobOptions.py.

## Public Member Functions
def | __init__
def | filter
def | printOn
def | printOff
def | disable
def | enable
## Public Attributes
| printing_level
| enabled
| threshold

## Member Function Documentation

def ProcessJobOptions::LogFilter::__init__ | ( |  | self,
|  |  | name = `""` |
| ) |  |  |

Definition at line 20 of file ProcessJobOptions.py.

    00020                                  :
    00021         logging.Filter.__init__(self, name)
    00022         self.printing_level = 0
    00023         self.enabled = True
    00024         self.threshold = logging.WARNING
        def filter(self, record):

def ProcessJobOptions::LogFilter::filter | ( |  | self,
|  |  | record |
| ) |  |  |

Definition at line 25 of file ProcessJobOptions.py.

    00025                             :
    00026         return record.levelno >= self.threshold or (self.enabled and self.printing_level <= 0)
        def printOn(self, step = 1, force = False):

def ProcessJobOptions::LogFilter::printOn | ( |  | self,
|  |  | step = `1`,
|  |  | force = `False` |
| ) |  |  |

    Decrease the printing_level of 'step' units. ( >0 means no print)
    The level cannot go below 0, unless the force flag is set to True.
    A negative value of the threshold disables subsequent "PrintOff"s.

Definition at line 27 of file ProcessJobOptions.py.

    00027                                               :
    00028         """
    00029         Decrease the printing_level of 'step' units. ( >0 means no print)
    00030         The level cannot go below 0, unless the force flag is set to True.
    00031         A negative value of the threshold disables subsequent "PrintOff"s.
    00032         """
    00033         if force:
    00034             self.printing_level -= step
    00035         else:
    00036             if self.printing_level > step:
    00037                 self.printing_level -= step
    00038             else:
    00039                 self.printing_level = 0
        def printOff(self, step = 1):

def ProcessJobOptions::LogFilter::printOff | ( |  | self,
|  |  | step = `1` |
| ) |  |  |

    Increase the printing_level of 'step' units. ( >0 means no print)

Definition at line 40 of file ProcessJobOptions.py.

    00040                                 :
    00041         """
    00042         Increase the printing_level of 'step' units. ( >0 means no print)
    00043         """
    00044         self.printing_level += step
        def disable(self, allowed = logging.WARNING):

def ProcessJobOptions::LogFilter::disable | ( |  | self,
|  |  | allowed = `logging.WARNING` |
| ) |  |  |

Definition at line 45 of file ProcessJobOptions.py.

    00045                                                 :
    00046         self.enabled = False
    00047         self.threshold = allowed
        def enable(self, allowed = logging.WARNING):

def ProcessJobOptions::LogFilter::enable | ( |  | self,
|  |  | allowed = `logging.WARNING` |
| ) |  |  |

Definition at line 48 of file ProcessJobOptions.py.

    00048                                                :
    00049         self.enabled = True
    00050         self.threshold = allowed
    00051
    class ConsoleHandler(logging.StreamHandler):

## Member Data Documentation

ProcessJobOptions::LogFilter::printing_level

Definition at line 22 of file ProcessJobOptions.py.

ProcessJobOptions::LogFilter::enabled

Definition at line 23 of file ProcessJobOptions.py.

ProcessJobOptions::LogFilter::threshold

Definition at line 24 of file ProcessJobOptions.py.

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

- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v21r6/GaudiKernel/python/GaudiKernel/ProcessJobOptions.py