Package Products :: Package ZenEvents :: Module MailProcessor :: Class MessageProcessor |
[hide private]
[frames] | no frames]

# Class MessageProcessor

source code

    object --+
             |
            MessageProcessor

Base class for parsing email messages that are retrieved via POP or received via SMTP.

Instance Methods | [hide private]
__init__(self, zem, defaultSeverity=2) Initializer | source code
process(self, messageStr) Convert an e-mail message into a Zenoss event. | source code
enrich(self, event, subject) Sanitize the event facility and severity fields. | source code
simple class |
buildEventClassKey(self, evt) Set the Zenoss eventClassKey | source code
Inherited from `object`: `__delattr__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__str__`

Properties | [hide private]
Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, zem, defaultSeverity=2) (Constructor) | source code
Initializer Parameters: `zem` (Zenoss event manager object) - class that provides sendEvent() method `defaultSeverity` (integer) - severity level to use if we can't figure one out Overrides: object.__init__

### process(self, messageStr) | source code
Convert an e-mail message into a Zenoss event. Parameters: `messageStr` (string) - e-mail message

### enrich(self, event, subject) | source code
Sanitize the event facility and severity fields. Parameters: `event` (simple class) - event `subject` (string) - e-mail subject (unused)

### buildEventClassKey(self, evt) | source code
Set the Zenoss eventClassKey Parameters: `evt` (simple class) - event Returns: simple class modified event