| Trees | Indices | Help |
|
|---|
|
|
Products.ZenUtils.ZCmdBase.ZCmdBase --+
|
xml.sax.handler.ContentHandler --+
|
ImportRM
Wrapper module to interface between Zope and the Python SAX XML library.
The xml.sax.parse() calls different routines depending on what it finds.
A simple example of a valid XML file can be found in the objects.xml file
for a ZenPack.
<?xml version="1.0"?>
<objects>
<!-- ('', 'zport', 'dmd', 'Devices', 'rrdTemplates', 'HelloWorld') -->
<object id='/zport/dmd/Devices/rrdTemplates/HelloWorld' module='Products.ZenModel.RRDTemplate' class='RRDTemplate'>
<property type="text" id="description" mode="w" > This is the glorious description that shows up when we click on our RRD template </property>
<tomanycont id='datasources'>
<object id='hello' module='Products.ZenModel.BasicDataSource' class='BasicDataSource'>
<property select_variable="sourcetypes" type="selection" id="sourcetype" mode="w" > SNMP </property>
<property type="boolean" id="enabled" mode="w" > True </property>
<property type="string" id="eventClass" mode="w" > /Cmd/Fail </property>
<property type="int" id="severity" mode="w" > 3 </property>
<property type="int" id="cycletime" mode="w" > 300 </property>
<property type="boolean" id="usessh" mode="w" > False </property>
<tomanycont id='datapoints'>
<object id='hello' module='Products.ZenModel.RRDDataPoint' class='RRDDataPoint'>
<property select_variable="rrdtypes" type="selection" id="rrdtype" mode="w" > GAUGE </property>
<property type="boolean" id="isrow" mode="w" > True </property>
</object>
</tomanycont>
</object>
<!-- snip -->
</objects>
|
|||
|
|||
| object |
|
||
| list |
|
||
|
|||
|
|||
|
|||
| object |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Inherited from |
|||
|
|||
rootpath = ''
|
|||
skipobj = 0
|
|||
|
|||
|
|
|
|
|
Called by xml.sax.parse() with data found in an element eg <object>my characters stuff</object> Note that this can be called character by character.
|
|
|
|
This method can be used to load data for the root of Zenoss (default behavior) or it can be used to operate on a specific point in the Zenoss hierarchy (ZODB). Upon loading the XML file to be processed, the content of the XML file is handled by the methods in this class when called by xml.sax.parse(). Reads from a file if xmlfile is specified, otherwise reads from the command-line option --infile. If no files are found from any of these places, read from standard input.
|
| Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0beta1 on Thu May 7 11:46:16 2009 | http://epydoc.sourceforge.net |