I think it is a .net problem as well but because I had no luck to change the behaviour there I thought it could be possible to let axis understand it. I think this is nothing special and interopability should be possible. I haven't found a bug reporter @microsoft but posted a message in the dotnet.framework.webservices newsgroup.
If anyone has an idea how to solve this I would appreciate. Thanks! -David On Monday 28 July 2003 20:27, you wrote: > But this is a problem with .NET. It shouldn't create a child element. > Have you logged a bug with Microsoft? > > ----- Original Message ----- > From: "David Kocher" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Monday, July 28, 2003 12:26 PM > Subject: interopability with xs:simpleType > > > Hi axis-users, > > I have a soap interoparibilty problem between axis and .net with simple > > xsd > > > types and how they are transformed into a soap xml message. > > > > Assuming a type like the following: > > <xs:simpleType name="ZIP-CodeType"> > > <xs:restriction base="xs:NMTOKEN"> > > <xs:minLength value="4"/> > > <xs:maxLength value="6"/> > > </xs:restriction> > > </xs:simpleType> > > > > In the axis generated soap body this will look like > > > > <multiRef id="id10" soapenc:root="0" > > soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" > > xsi:type="ns13:ZIP-CodeType" > > xmlns:ns13="http://www.itserve.ch/schemas/20030722/SalaryDeclaration" > > xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"> > > 3000 > > </multiRef> > > > > where '3000' is the value. > > > > The equivalent soap serialization by .net looks like this > > <tns:ZIP-CodeType id="id13" xsi:type="tns:ZIP-CodeType"> > > <Value xsi:type="xsd:NMTOKEN">3000</Value> > > </tns:ZIP-CodeType> > > > > Axis will throw a fault because it does not expect a child element in the > > ZIP-CodeType. > > > > If I change the xs:simpleType into a xs:complexType the axis soap body > > will > > > look similar the .net style but then I have the problem that it is not > > possible to have a restriction in a complexType. > > > > Is there any chance to change this behaviour on the axis side? > > (Unfortunately > > > I had no luck on the .NET side, there's is no c# attribute to customize > > the > > > mapping) > > > > Thanks in advance! > > -David
