search for: check_dom_against_dtd

Displaying 1 result from an estimated 1 matches for "check_dom_against_dtd".

2010 Oct 08
7
[PATCH] Replace pyxml/xmlproc-based XML validator with lxml based one.
...gs.warn(''DTD file %s not found.'' % (self.dtd), + UserWarning) + return + + tree = etree.parse(file) + root = tree.getroot() + if not dtd.validate(root): + self.handle_dtd_errors(dtd) + def check_dom_against_dtd(self, dom): """ Check DOM again DTD. Doesn''t give as nice error messages. (no location info) """ - dtd = xmldtd.load_dtd(self.dtd) - app = xmlval.ValidatingApp(dtd, self) - app.set_locator(self)...