Project

General

Profile

« Previous | Next » 

Revision 307

bin/map: Refactored to print document opening, contents, and closing in separate steps so they can be separated later

View differences:

bin/map
166 166
    else: # output is XML
167 167
        def use_row(root): pass # TODO: implement this
168 168
        output = sys.stdout
169
        config = xml_dom.prettyxml_config
169 170
        doc1 = get_xml(use_row)
170
        doc1.writexml(output, **xml_dom.prettyxml_config)
171
        doc1.write_opening(output, **config)
172
        for child in doc1.firstChild: child.writexml(output, indent=1, **config)
173
        doc1.write_closing(output, **config)
171 174

  
172 175
try: main()
173 176
except Parser.SyntaxException, e: raise SystemExit(str(e))

Also available in: Unified diff