axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cory Wilkerson" <>
Subject RE: xmlns=" " in the doc\literal SOAP message
Date Tue, 02 Sep 2003 14:02:34 GMT

When you say "local" elements -- do you mean local to the parent element as defined in the
schema?  In the following example, would bar and baz be considered local elements?  

<schema targetName=""/>
	<complexType name="foo>
			<element name="bar" type="xsd:string"/>
			<element name="baz" type="xsd:string"/>

I would think when this was serialized to the wire you'd see something like:

<foo xmlns="">

After all, don't bar and baz technically belong to the namespace?  

Thanks for any input,
Cory WIlkerson

-----Original Message-----
From: Anne Thomas Manes []
Sent: Tuesday, September 02, 2003 8:40 AM
Subject: Re: xmlns=" " in the doc\literal SOAP message


Yes. It's okay for empty namespace definitions to go across the wire. In 
fact, it some cases it might be required.

In your SOAP request, the <query> element defines a default namespace 
(xmlns="blah" as opposed to xmlns:foo="blah"), which then applies to all 
subelements of the <query> element, unless it is overridden by another 
default namespace definition. If the <description> and <ItemId> elements 
are local elements to <query>, then they should not be namespace qualified, 
and in that case, you should specify an empty default namspace definition 
in each of these subelements to override the active default namespace.

Now, if the <description> and <ItemId> are global elements, then this 
message would be in error.

So whether or not this message is correct depends on the schema definition 
for the message.


At 02:20 AM 9/1/2003 -0700, you wrote:
>Hi all,
>I'm trying to write a doc\literal web service and my soap message appears 
>as below.........
><query xmlns="urn:HistorySriLanka">
>    <description xmlns="">Wood carving of an Elephant</description>
>    <ItemId xmlns="">ER234</ItemId>
>Has anybody else has come across a situation like this? Is it ok for empty 
>xmlns="" tags to go in the wire? Any help is greatly appreciated.
>Thank you,
>Do you Yahoo!?
>SiteBuilder - Free, easy-to-use web site design software

View raw message