Subject: | ComplexTypes' elements in different namespaces not serialized correctly |
Date: | Tue, 14 Apr 2009 21:40:46 +0200 |
To: | SOAP-WSDL RT <bug-SOAP-WSDL [...] rt.cpan.org> |
From: | Martin Kutter <martin.kutter [...] fen-net.de> |
Given the following schemata:
<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
targetNamespace="uri:Foo"
xmlns:test="http://www.example.org/ElementNamespaces/"
elementFormDefault="qualified">
<xsd:complexType name="complexTest">
<xsd:sequence>
<xsd:element name="Blam" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
and
<xsd:schema targetNamespace="uri:Bar" elementFormDefault="qualified">
<xsd:import namespace="uri:Foo"
schemaLocation="MultipleNamespaces.xsd" />
<xsd:complexType name="Baz">
<xsd:sequence>
<xsd:element name="Local" type="xsd:string"/>
<xsd:element name="Bar" type="test:complexTest"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
the complexType "Baz" is serialized incorrectly as
<Local></Local>
<Bar>
<Blam><Blam>
</Bar>
while it should be serialized as
<Local></Local>
<Bar>
<Blam xmlns="uri:Foo"><Blam>
</Bar>