| The Gaudi Framework v32r1 (f65d50dc)

Public Member Functions | Public Attributes | List of all members
GaudiKernel.ProcessJobOptions.LogFormatter Class Reference
Inheritance diagram for GaudiKernel.ProcessJobOptions.LogFormatter:
[legend]
Collaboration diagram for GaudiKernel.ProcessJobOptions.LogFormatter:
[legend]

## Public Member Functions
def | __init__ (self, fmt=None, datefmt=None, prefix="# ", with_time=False)
def | format (self, record)

## Public Attributes
| prefix
| with_time

## Detailed Description

Definition at line 10 of file ProcessJobOptions.py.

## Constructor & Destructor Documentation

## ◆ __init__()

def GaudiKernel.ProcessJobOptions.LogFormatter.__init__ | ( |  | self,
|  |  | fmt = `None`,
|  |  | datefmt = `None`,
|  |  | prefix = `"# "`,
|  |  | with_time = `False`
| ) |  |

Definition at line 11 of file ProcessJobOptions.py.

11 def __init__(self, fmt=None, datefmt=None, prefix="# ", with_time=False):
12 logging.Formatter.__init__(self, fmt, datefmt)
13 self.prefix = prefix
14 self.with_time = with_time
15

## Member Function Documentation

## ◆ format()

def GaudiKernel.ProcessJobOptions.LogFormatter.format | ( |  | self,
|  |  | record
| ) |  |

Definition at line 16 of file ProcessJobOptions.py.

16 def format(self, record):
17 fmsg = logging.Formatter.format(self, record)
18 prefix = self.prefix
19 if self.with_time:
20 prefix += '%f ' % time.time()
21 if record.levelno >= logging.WARNING:
22 prefix += record.levelname + ": "
23 s = "\n".join([prefix + line for line in fmsg.splitlines()])
24 return s
25
26
format
GAUDI_API std::string format(const char *,...)
MsgStream format utility "a la sprintf(...)".
Definition: MsgStream.cpp:109

## Member Data Documentation

## ◆ prefix

GaudiKernel.ProcessJobOptions.LogFormatter.prefix

Definition at line 13 of file ProcessJobOptions.py.

## ◆ with_time

GaudiKernel.ProcessJobOptions.LogFormatter.with_time

Definition at line 14 of file ProcessJobOptions.py.

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

- GaudiKernel/python/GaudiKernel/ProcessJobOptions.py