Oxygen XML Editor
 
[XML-DEV Mailing List Archive Home] [By Thread] [By Date]

RE: [xml-dev] ID Conflicts in Namespaces.


  • From: "Michael Kay" <mike@...>
  • To: "'Ben Trafford'" <ben@...>,<xml-dev@...>
  • Date: Fri, 18 Aug 2006 09:02:55 +0100

>          Thanks for the response. I tried to dig up that 
> information in various specs, and couldn't find anything 
> (which may speak more to my spec-reading abilities than 
> anything, but there you go.)
> 
>          Where are you drawing your information from?

You start to understand the XML Schema Part 1 spec on about the fifth
reading, if you can stay awake and concentrate.

Section 2.1 starts:

An XML Schema consists of components such as type definitions and element
declarations. These can be used to assess the validity of well-formed
element and attribute information items (as defined in [XML-Infoset]), and
furthermore may specify augmentations to those items and their descendants. 

Section 4.1 explains:

[Validity] .assessment. is defined with reference to an .XML Schema. (note
not a .schema document.) which consists of (at a minimum) the set of schema
components (definitions and declarations) required for that .assessment.. 

In other words, you assemble a schema from a set of schema components which
may or may not originate from a set of schema documents, and you use this
set of schema components to perform validation.

The specific rules for ID/IDREF are described in:

Validation Rule: Validation Root Valid (ID/IDREF)
For an element information item which is the .validation root. to be .valid.
all of the following must be true:
1 There must be no ID/IDREF binding in the item's [ID/IDREF table] whose
[binding] is the empty set.
2 There must be no ID/IDREF binding in the item's [ID/IDREF table] whose
[binding] has more than one member.

For this you need to understand the way the ID/IDREF table work; but in
priciple it's simple: if an element or attribute is validated as an instance
of xs:ID then it is added to the table. There's only one such table for a
validation episode, so it's irrelevant where the constraints were defined.

Michael Kay
http://www.saxonica.com/




[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
 
© 2002-2008 SyncRO Soft Ltd. All rights reserved. | Sitemap | Privacy Policy
This website was created & generated with <oXygen/> XML Editor
Keywords