W3C home > Mailing lists > Public > public-xml-core-wg@w3.org > November 2008

FW: Schematron for checking xml:id?

From: Grosso, Paul <pgrosso@ptc.com>
Date: Mon, 10 Nov 2008 09:38:23 -0500
Message-ID: <CF83BAA719FD2C439D25CBB1C9D1D3020D5702D1@HQ-MAIL4.ptcnet.ptc.com>
To: <public-xml-core-wg@w3.org>

Any thoughts?

paul

-----Original Message-----
From: public-xml-id-request@w3.org On Behalf Of Chris Lilley
Sent: Monday, 2008 November 10 8:33
To: public-xml-id@w3.org
Subject: Schematron for checking xml:id?


Hello public-xml-id,

Following this thread
http://lists.w3.org/Archives/Public/public-xml-id/2008Aug/thread.html

which demonstrates that (since Relax-NG does not modify the infoset)
xl:id should be declared as NCNAME in a RelaxNG schema, I was wondering
whether Schematron could be used to check various aspects of IDness? In
particular I was wondering if anyone had already done it :)

SVG, which introduced xml:id to a language that already had @id of type
ID, 
http://www.w3.org/TR/SVGMobile12/struct.html#Core.attrib

tries to give guidance on document authoring and document processing in
the case that both attributes are used in the same document
http://www.w3.org/TR/SVGMobile12/struct.html#idAttrs


Since these are co-constraints, it looks as if Schamatron could help in
checking this:

a) warn if an element has both @id and @xml:id with different values
b) check ID uniqueness by first converting @id to @xml:id for any
element that has @id and does not have @xml:id, then using an
xml:id-aware processor

Does this seem like a feasible approach?



-- 
 Chris Lilley                    mailto:chris@w3.org
 Technical Director, Interaction Domain
 W3C Graphics Activity Lead
 Co-Chair, W3C Hypertext CG
Received on Monday, 10 November 2008 14:39:25 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:16:39 UTC