Package Products :: Package ZenEvents :: Module xtest :: Class XTest |
[hide private]
[frames] | no frames]

# Class XTest

source code

                  object --+
                           |
    ZenUtils.CmdBase.CmdBase --+
                               |
                              XTest

Instance Methods | [hide private]
__init__(self, noopts=0) | source code
buildOptions(self) basic options setup sub classes can add more options here | source code
parseEventsFile(self, filepath=None) Not much actual parsing going on here, just importing the given file. | source code
getXmlRpcProxy(self) Returns xmlrpc proxy, creating on if the instance doesn't already have one. | source code
sendEvents(self, events) events is a list of dictionaries with details of events to send. | source code
sendSampleEvents(self, repeat=1) Sends the sample event and corresponding clear event. | source code
sendSampleWithDelayedClear(self, repeat=1, delay=30) Sends sample event then after a delay sends the clear event, repeating as specified. | source code
sendEventsFromFile(self, filepath=None) Parse the given file (or the file specified at init) and send the files. | source code
Inherited from `ZenUtils.CmdBase.CmdBase`: `buildParser`, `checkLogpath`, `generate_configs`, `generate_xml_configs`, `generate_xml_table`, `getConfigFileDefaults`, `parseOptions`, `pretty_print_config_comment`, `setupLogging` Inherited from `object`: `__delattr__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__str__`

Class Variables | [hide private]
| sampleEvent = `dict(device= 'Sample device', summary= 'Test eve`...``
| sampleClear = `sampleEvent.copy()`
Inherited from `ZenUtils.CmdBase.CmdBase`: `doesLogging`

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

Method Details | [hide private]

### __init__(self, noopts=0) (Constructor) | source code
Overrides: ZenUtils.CmdBase.CmdBase.__init__

### buildOptions(self) | source code
basic options setup sub classes can add more options here Overrides: ZenUtils.CmdBase.CmdBase.buildOptions

### sendEvents(self, events) | source code
events is a list of dictionaries with details of events to send. This sends those events via the xmlrpc proxy.

### sendSampleEvents(self, repeat=1) | source code
Sends the sample event and corresponding clear event. Repeats this as many times as specified by repeat.

Class Variable Details | [hide private]

  ### sampleEvent Value:
      dict(device= 'Sample device', summary= 'Test event at %s' % time.time(
      ), eventClass= Status_Perf, severity= 4, component= 'Sample component'
      )