Re: What would you like to see in XML::LibXML ?

Liam R E Quin <[email protected]> Mon, 03 Dec 2012 23:10:08 -0500
Newsgroups gmane.comp.lang.perl.xml
Organization W3C - World Wide Web Consortium
Message-ID <[email protected]>
On Mon, 2012-12-03 at 11:04 -0800, Francisco Obispo wrote:
> I'm just thinking that it would be interesting to have the parser look
> at the xmlns and see if there is a matching entry in the XML catalog,
> and if there is, it should use that for validation.

This is not a good idea.

The xsi:schemaLocationHint attribute is to be used for this purpose, not
random other URI-valued attributes :-)

A namespace URI does not in general point to a schema and should not be
used in that way.

> If that's not the case, we should then make really explicit that the
> ->validation(1) option is just really dtd_validation.
Validation in XML is usually DTD-based; schema processing, or a Schema
Validation Episode, is another matter.

There may also be several different XML Schemas (XSD) that one wants to
use for a given XML document, so any API should allow the programmer to
pass in a URI for a schema document.

Liam

-- 
Liam Quin - XML Activity Lead, W3C, http://www.w3.org/People/Quin/
Pictures from old books: http://fromoldbooks.org/

_______________________________________________
Perl-XML mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs