XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Re: [xml-dev] targetNamespace vs default namespace

----- Original Message From: "REV Tamas"

> Hi Pete,
>
> Thank you for your reply. It made me realize that I omitted some important
> data: the schema has elementFormDefault="qualified" and
> attributeFormDefault="unqualified":
>
> <xsd:schema xmlns="ProprietaryNamespace" targetNamespace="
> AnotherProprietaryNamespace"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
> elementFormDefault="qualified"
> attributeFormDefault="unqualified"
> xmlns:abc="YetAnotherPropriateryNamespace">
> ...
>    <xsd:complexType name="complexTypeOne">
>        <xsd:sequence>
>            ...
>            <xsd:element name="SubElementWithoutPrefix"
> type="ElementTypeWithoutPrefix" /> <!-- a line with a problem -->
>        </xsd:sequence>
>    </xsd:complexType>
>    ...
> </xsd:schema>
>
> This is the schema "as is" the customer gave us. This schema belongs to 
> the
> interface definition of a webservice.
> One of our tasks is to validate the messages sent to this interface. The
> customer gave us test messages too.
>
> ...
>
>
> The corresponding part looks like that:
> <Soapenv:Envelope 
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
> xmlns:ns1="AnotherProprietaryNamespace"> <!-- ns1 matches the
> targetNamespace of the schema -->
>    ...
>    <ns1:ComplexEelement>
>        ...
>        <ns1:SubElementWithoutPrefix>trallala</ns1:SubElementWithoutPrefix>
>        ...
>    </ns1:ComplexElement>
>
> If I understand it well, this message excrept conforms to the schema
> excrept, because elementFormDefault="qualified" means that the elements
> conforming to this schema must be qualified with the schemas 
> targetNamspace.

Hi Tama,

This looks right to me.

HTH,

Pete Cordell
Codalogic Ltd
Interface XML to C++ the easy way using XML C++
data binding to convert XSD schemas to C++ classes.
Visit http://codalogic.com/lmx/ or http://www.xml2cpp.com
for more info


(cc-ed to xml-dev list in case others want to follow updates.) 




[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


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

Copyright 1993-2007 XML.org. This site is hosted by OASIS