[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: RE: [wsdm] Question on targetNamespace in WSDM WSDL/XSD specs
Apparently not all tools support <xsd:include> equally well. Some would choke if
they have a definition of the schema with a given namespace in WSDL types
section and also schema definition of the same namespace in the included
file.
To avoid problems and improve interoperability one could
#1: inline all schema definition directly in the
<types> section, however that is not very reusable
#2: do what you have noticed in the WSDM schemas and WSDLs.
Imports work very reliably. Note that schema definition in WSDL is just a
"thunk", so to speak.
From: Ed Day [mailto:eday@obj-sys.com] Sent: Tuesday, March 16, 2004 10:44 AM To: wsdm@lists.oasis-open.org Subject: [wsdm] Question on targetNamespace in WSDM WSDL/XSD specs I was reviewing the recently released to WSDM
WSDL/XSD specs to see how they would work with our XML data binding tool.
I encountered a problem with the way namespaces were declared that I hope
someone can answer.
In looking at the MOWS.wsdl document, I see this at
the top level:
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
... targetNamespace="urn:wsdm:mows">
target namespace has been declared as
urn:wsdm:mows. Fair enough.
Later in the <types> section is the
following:
<xs:schema
elementFormDefault="qualified"
targetNamespace="urn:wsdm:mows:types" Looks like you want to dump the types into the
urn:wsdm:mows:types namespace. But in the XSD file, you revert back to the
urn:wsdm:mows namespace:
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
... targetNamespace="urn:wsdm:mows"
elementFormDefault="qualified" attributeFormDefault="unqualified"> It looks like the overall result is that all the
MOWS stuff is going to end up in the urn:wsdm:mows namespace. So then what
is the reason for having the urn:wsdm:mows:types namespace? My guess is
that it was put there to keep your XML schema validator from flagging an error
that you were trying to import items from a namespace into the same
namespace. If this is the case, you can eliminate this namespace and just
use <xsd:include> to pull in the MOWS types since they are in the same
namespace. Does this sound reasonable or was there some other reason for
doing it this way?
Regards,
Ed Day
Objective Systems, Inc. |
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]