| # Gaudi Framework, version v21r11 |

Home |  | Generated: 30 Sep 2010

# GaudiTest::RegexpReplacer Class Reference

Inheritance diagram for GaudiTest::RegexpReplacer:
[legend]
Collaboration diagram for GaudiTest::RegexpReplacer:
[legend]

List of all members.

## Public Member Functions
def | __init__
def | __add__
def | __processLine__
## Private Attributes
| _operations

## Detailed Description

Definition at line 388 of file GaudiTest.py.

## Member Function Documentation

def GaudiTest::RegexpReplacer::__init__ | ( |  | self,
|  |  | orig,
|  |  | repl = `""`,
|  |  | when = `None` |
| ) |  |  |

Definition at line 389 of file GaudiTest.py.

    00389                                                     :
    00390         if when:
    00391             when = re.compile(when)
    00392         self._operations = [ (when, re.compile(orig), repl) ]
        def __add__(self,rhs):

def GaudiTest::RegexpReplacer::__add__ | ( |  | self,
|  |  | rhs |
| ) |  |  |

Reimplemented from GaudiTest::FilePreprocessor.

Definition at line 393 of file GaudiTest.py.

    00393                          :
    00394         if isinstance(rhs, RegexpReplacer):
    00395             res = RegexpReplacer("","",None)
    00396             res._operations = self._operations + rhs._operations
    00397         else:
    00398             res = FilePreprocessor.__add__(self, rhs)
    00399         return res
        def __processLine__(self, line):

def GaudiTest::RegexpReplacer::__processLine__ | ( |  | self,
|  |  | line |
| ) |  |  |

Reimplemented from GaudiTest::FilePreprocessor.

Definition at line 400 of file GaudiTest.py.

    00400                                    :
    00401         for w,o,r in self._operations:
    00402             if w is None or w.search(line):
    00403                 line = o.sub(r, line)
    00404         return line
    00405
    00406 # Common preprocessors
    maskPointers  = RegexpReplacer("0x[0-9a-fA-F]{4,16}","0x########")

## Member Data Documentation

GaudiTest::RegexpReplacer::_operations`[private]`

Definition at line 392 of file GaudiTest.py.

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

- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v21r11/GaudiPolicy/qmtest_classes/GaudiTest.py