gp_parse: Add a generalize XML function to the top level parser
authorGarming Sam <garming@catalyst.net.nz>
Mon, 28 May 2018 23:57:26 +0000 (11:57 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 16 Aug 2018 21:42:22 +0000 (23:42 +0200)
commitabff0c4f4d2620b2fb86c8325950f8e95b5992d7
tree1c9943520f53c24b683b220b500e7d1763e298a6
parent57dd88ce5cde29462b77f2f1a5d0035573721c4e
gp_parse: Add a generalize XML function to the top level parser

In this function we take XML and using the required metadata, we rewrite
it into a generic form using entities. ElementTree unfortunately does
not allow us to store unescaped entities, and so we must do a textual
replace on the output XML.

Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
python/samba/gp_parse/__init__.py