Re: XPath Data Model proposal

Jeni Tennison scripsit:

> Just to fill in the gaps here, presumably you're only suggesting that
> an XPath 2.0 processor be able to do anything with xsi:type attributes
> holding the names of types that it recognises, and that other type
> annotations should be ignored?

In effect, I think that is achieved by the penultimate paragraph in
3.6, which says that unknown types are to be promoted to xs:anyType or
xs:anySimpleType, as the case may be.

> Also, I assume that you're suggesting that the XPath 2.0 processor
> validate the content of the annotated element, such that, for example
> <foo xsi:type="xs:integer">rubbish</foo> isn't labelled as being of
> type xs:integer. Or are you suggesting that elements be labelled with
> types without necessarily being valid against those types?

Hmm, that's a point I hadn't considered.  It's formally messy, because
there is no formal definition of type validity in the DM -- it can
delegate to the XML Schema documentation for that.  OTOH, asking an XPath
processor to cope with examples like that is more than a bit awkward.

> (The same answers will apply to xdt:attributeTypes, I imagine.)

Indeed.

-- 
John Cowan  jcowan@reutershealth.com  www.reutershealth.com  www.ccil.org/~cowan
I am he that buries his friends alive and drowns them and draws them
alive again from the water. I came from the end of a bag, but no bag
went over me.  I am the friend of bears and the guest of eagles. I am
Ringwinner and Luckwearer; and I am Barrel-rider.  --Bilbo to Smaug

Received on Thursday, 5 June 2003 12:50:04 UTC