def _asDict(self): """ Gets the dict representation of the object """ # Use OFS exportXML to first export to xml f = StringIO() XMLExportImport.exportXML(self._p_jar, self._p_oid, f) # Get the value of exported XML xml_value = f.getvalue() return xmltodict.parse(xml_value)
def export_object_to_xml(ob, fp): XMLExportImport.exportXML(ob._p_jar, ob._p_oid, fp)