Routines for Run-Time Generation of Main Driver Filter XML Descriptions ((mango.application.main_driver.xml_generator)

Functions for generating XML filter descriptions (<install_prefix>/share/pymango.xml). Simply inspects all main-driver registered filter classes and accumlates the individual XML descriptions (using the mango.application.main_driver.MainDriverFilter.getXmlFileName() or mango.application.main_driver.MainDriverFilter.getXmlString() methods).

See also

Class mango.application.main_driver.MainDriverFilter
Base class for main-driver filters.

Main Functions

generateXmlFromCommandLineArgs(args) Main routine used to generate the '<install_prefix>/share/pymango.xml' XML file which describes main-driver filters and data-types.
generatePyMangoFilterDescriptionXml([...]) Generate the XML filter description string (e.g.
generatePerFilterClassXmlString(filterClsList) Returns XML string describing the filters/filter-parameters of the given main-driver filter classes.

Helper Functions

Most of the helper functions which return a str look for the relevant method attribute on a filter class before calling the method, if the attribute isn’t present, then None is returned.

getXmlString(filterCls) Returns the string filterCls.getXmlString().
readXmlStringFromXmlFileName(filterCls) Returns the string read from the file named filterCls.getXmlFileName().
getParmSectionName(filterCls) Returns filterCls.parmSectionName().
checkXmlFromFile(xmlFileName[, parmSectName]) Reads entire file into string and calls checkXmlFromString to validate the XML.
checkXmlFromString(xmlDocumentStr[, ...]) Validates specified XML string by creating a xml.etree.ElementTree by calling xml.etree.ElementTree.fromstring(xmlDocumentStr).
makeXmlDoc(xmlStr) Turns XML tag string into XML document which can be validated by xml.etree.ElementTree parser.