OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] qname resolution question

[ Lists Home | Date Index | Thread Index ]

OK, I'll make an attempt to do so when I have time...
(I need to verify the behaviour using brand new beta before
 doing so.)

Another thing is that we'll not get into this kind of errors again
if such cases correctly are entered into the w3c schema test collections
to which all processors are supposed to eventually comform.
(I know some of the test cases there are broken, which makes it
 hard to test with it. Maybe we need a test cases for test cases? :-)

-Takuki Kamiya


----- Original Message -----
From: "Dare Obasanjo" <kpako@yahoo.com>
To: "Takuki Kamiya" <takuki@pacbell.net>; <xml-dev@lists.xml.org>
Sent: Saturday, December 29, 2001 4:39 AM
Subject: Re: [xml-dev] qname resolution question


> I suggest mailing bug reports to the Xerces team and Henry Thompson so the
> issue can be resolved in both parsers.
>
> --
> THINGS TO DO IF I BECOME AN EVIL OVERLORD #18
> I will not have a son. Although his laughably under-planned attempt to
usurp
> power would easily fail, it would provide a fatal distraction at a crucial
> point in time.
>
> ----- Original Message -----
> From: "Takuki Kamiya" <takuki@pacbell.net>
> To: "Dare Obasanjo" <kpako@yahoo.com>; <xml-dev@lists.xml.org>
> Sent: Friday, December 28, 2001 7:45 PM
> Subject: Re: [xml-dev] qname resolution question
>
>
> > Hi Dare,
> >
> > Thanks for checking with .NET XML Reader.
> >
> > My schema processor which rejects such schemas seems to be
> > consistent with MS behaviour. :-) It is sometimes difficult to write a
> > XML schema which passes validation by all processors out there,
> > which I hope will be improved.
> >
> > -Takuki Kamiya
> >
> >
> > ----- Original Message -----
> > From: "Dare Obasanjo" <kpako@yahoo.com>
> > To: "Takuki Kamiya" <takuki@pacbell.net>; <xml-dev@lists.xml.org>
> > Sent: Friday, December 28, 2001 9:42 PM
> > Subject: Re: [xml-dev] qname resolution question
> >
> >
> > > I tried the schema on MSFT .NET's XmlValidatingReader and got the
> > following
> > > message
> > >
> > >     ERROR: The 'http://www.w3.org/2001/XMLSchema:documentBody' element
is
> > not
> > > declared.
> > >
> > > which I think is correct and the wrong answer is that being given by
XSV
> > and
> > > Xerces.
> > >
> > >
> > > From section 3.15.3 [Constraints on XML Representations of Schemas] of
the
> > W3C
> > > XML schemas Structures recommnedation, part 2.2.1 states that
> > >
> > > "Where the type of an attribute information item in a document
involved in
> > > ·validation· is identified as ·QName·, its ·actual value· is composed
of a
> > > local name and a  namespace name. Its ·actual value· is determined
based
> > on
> > > its ·normalized value· and the containing element information item's
> > [in-scope
> > > namespaces] following [XML-Namespaces]:
> > >
> > > The appropriate case among the following must be true:
> > >
> > >   2 otherwise (its ·normalized value· is unprefixed) all of the
following
> > must
> > > be true:
> > > 2.1 its ·local name· is its ·normalized value·.
> > > 2.2 The appropriate case among the following must be true:
> > > 2.2.1 If there is a namespace in the [in-scope namespaces] whose
[prefix]
> > has
> > > no value, then its ·namespace name· is the [namespace name] of that
> > > namespace." [0]
> > >
> > > So from the above, this seems to mean when trying to resolve the qname
of
> > > documentBody in the ref attribute of the element it ends up as
> > > http://www.w3.org/2001/XMLSchema:documentBody.
> > >
> > >
> > >
> > > But looking at section 3.3.2 [XML Representation of Element
Declaration
> > Schema
> > > Components] it should be noted in the table for the element Element
> > > Information Item there exists the following
> > >
> > >       Element Declaration Schema Component
> > >             Property Representation
> > >
> > >             {target namespace} The ·actual value· of the
targetNamespace
> > > [attribute] of the parent <schema> element information item, or
·absent·
> > if
> > > there is none
> > >
> > >
> > > so the from the documentBody's declaration it actually has no
> > targetNameSpace.
> > > Thus its qname should be "documentBody".
> > >
> > >
> > > Thus the MSFT error message seems to be correct since there is no
> > documentBody
> > > element declared in the http://www.w3.org/2001/XMLSchema namespace
while
> > XSV
> > > and Xerces look like they are incorrect.
> > >
> > > --
> > > THINGS TO DO IF I BECOME AN EVIL OVERLORD #18
> > > I will not have a son. Although his laughably under-planned attempt to
> > usurp
> > > power would easily fail, it would provide a fatal distraction at a
crucial
> > > point in time.
> > >
> > > ----- Original Message -----
> > > From: "Takuki Kamiya" <takuki@pacbell.net>
> > > To: <xml-dev@lists.xml.org>
> > > Sent: Friday, December 28, 2001 1:59 PM
> > > Subject: [xml-dev] qname resolution question
> > >
> > >
> > > > Hi,
> > > >
> > > > I am wondering if the following schema is valid or not.
> > > > (I tend to think it is invalid.)
> > > >
> > > > Both XSV and xerces passes validation with it.
> > > >
> > > > What is the namespace name for the "documentBody"
> > > > qname below? Is it "http://www.w3.org/2001/XMLSchema";,
> > > > or is it none (as targetNamespace is not provided)?
> > > >
> > > > Thanks in advance.
> > > >
> > > >
> > > > <?xml version ="1.0"?>
> > > > <schema xmlns="http://www.w3.org/2001/XMLSchema"; >
> > > >
> > > >   <element name = "envelope">
> > > >     <complexType>
> > > >       <sequence>
> > > >         <element ref = "documentBody"/>
> > > >       </sequence>
> > > >     </complexType>
> > > >   </element>
> > > >
> > > >   <element name = "documentBody" type="anyType"/>
> > > >
> > > > </schema>
> > > >
> > > > -Takuki Kamiya
> > > >
> > > >
> > > >
> > > > -----------------------------------------------------------------
> > > > The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> > > > initiative of OASIS <http://www.oasis-open.org>
> > > >
> > > > The list archives are at http://lists.xml.org/archives/xml-dev/
> > > >
> > > > To subscribe or unsubscribe from this list use the subscription
> > > > manager: <http://lists.xml.org/ob/adm.pl>
> > >
> > >
> > > _________________________________________________________
> > > Do You Yahoo!?
> > > Get your free @yahoo.com address at http://mail.yahoo.com
> > >
> > >
> > > -----------------------------------------------------------------
> > > The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> > > initiative of OASIS <http://www.oasis-open.org>
> > >
> > > The list archives are at http://lists.xml.org/archives/xml-dev/
> > >
> > > To subscribe or unsubscribe from this list use the subscription
> > > manager: <http://lists.xml.org/ob/adm.pl>
> > >
> >
> >
> > -----------------------------------------------------------------
> > The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> > initiative of OASIS <http://www.oasis-open.org>
> >
> > The list archives are at http://lists.xml.org/archives/xml-dev/
> >
> > To subscribe or unsubscribe from this list use the subscription
> > manager: <http://lists.xml.org/ob/adm.pl>
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS