qubes.convert_qubes_xml_to_json

Convert an XML file to a JSON file.

https://qubeshub.org/oaipmh/?verb=ListRecords&metadataPrefix=oai_dc&set=publications” curl URL > qubes_records.xml – or – wget URL -O qubes_records.xml

Attributes

here

msg

msg

old_dict

new_dict

Functions

old_to_new_dict(→ dict[str, str])

Doctest:

xml_to_dict(→ dict | list | str | None)

Convert an XML element and its children to a dictionary.

convert_xml_to_json(→ None)

Convert XML file to JSON file.

Module Contents

qubes.convert_qubes_xml_to_json.here
qubes.convert_qubes_xml_to_json.msg
qubes.convert_qubes_xml_to_json.msg
qubes.convert_qubes_xml_to_json.old_dict
qubes.convert_qubes_xml_to_json.new_dict
qubes.convert_qubes_xml_to_json.old_to_new_dict(old_dict: dict[str, dict | str]) dict[str, str]

Doctest: >>> old_to_new_dict(old_dict) == new_dict True

qubes.convert_qubes_xml_to_json.xml_to_dict(element: xml.etree.ElementTree.Element) dict | list | str | None

Convert an XML element and its children to a dictionary.

qubes.convert_qubes_xml_to_json.convert_xml_to_json(xml_file: os.PathLike, json_file: os.PathLike) None

Convert XML file to JSON file.