Hi, AXIS2 can not correctly map java data type, java.math.BigDecimal,
org.apache.axis2.databinding.type.Duration to corresponding xml data type
Decimal and Duration in the WSDL[1] generated by AXIS2. It considers
BigDecimal, Duration as complex type and further serialize their member
fields.
Is there anyway to disable this? Just map them to corresponding XML data
type? Many thanks in advance.
best regards
donald
[1] the generated WSDL by AXIS2
<wsdl:definitions xmlns:axis2="http://ws.apache.org/axis2" xmlns:mime="
http://schemas.xmlsoap.org/wsdl/mime/" xmlns:http="
http://schemas.xmlsoap.org/wsdl/http/" xmlns:ns0="http://math.java/xsd"
xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:ns1="
http://ws.apache.org/axis2/xsd" xmlns:ns2="
http://types.databinding.axis2.apache.org/xsd" xmlns:xs="
http://www.w3.org/2001/XMLSchema" xmlns:soap="
http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="
http://schemas.xmlsoap.org/wsdl/" targetNamespace="
http://ws.apache.org/axis2"><wsdl:documentation<http://ws.apache.org/axis2%22%3E%3Cwsdl:documentation>
This is an example of web service
</wsdl:documentation><wsdl:types><xs:schema xmlns:ax217="
http://math.java/xsd" attributeFormDefault="qualified"
elementFormDefault="qualified" targetNamespace="http://math.java/xsd">
*<xs:element name="BigDecimal" type="ax217:BigDecimal" />
<xs:complexType name="BigDecimal">
<xs:sequence>
<xs:element name="scale" type="xs:int" />
</xs:sequence>
</xs:complexType>
*</xs:schema><xs:schema xmlns:ax218="http://math.java/xsd" xmlns:ns="
http://ws.apache.org/axis2/xsd" xmlns:ax220="
http://types.databinding.axis2.apache.org/xsd"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://ws.apache.org/axis2/xsd">
<xs:import namespace="http://math.java/xsd" />
<xs:import namespace="http://types.databinding.axis2.apache.org/xsd" />
<xs:element name="placeOrder">
<xs:complexType>
<xs:sequence>
<xs:element name="customerID" nillable="true" type="xs:string" />
<xs:element name="order" nillable="true" type="ns:Order" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="Order" type="ns:Order" />
<xs:complexType name="Order">
<xs:sequence>
<xs:element name="orderID" nillable="true" type="xs:string" />
<xs:element name="startingDate" type="xs:dateTime" />
<xs:element name="totalAmount" nillable="true" type*="ax218:BigDecimal"* />
<xs:element name="warrentyPeriod" nillable="true"* type="ns2:Duration*" />
</xs:sequence>
</xs:complexType>
<xs:element name="placeOrderResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="return" nillable="true" type="xs:base64Binary" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema><xs:schema xmlns:ax219="
http://types.databinding.axis2.apache.org/xsd"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://types.databinding.axis2.apache.org/xsd">
<xs:element name="Duration" type="ns2:Duration" />
*<xs:complexType name="Duration">
<xs:sequence>
<xs:element name="asCalendar" type="xs:dateTime" />
<xs:element name="days" type="xs:int" />
<xs:element name="hours" type="xs:int" />
<xs:element name="minutes" type="xs:int" />
<xs:element name="months" type="xs:int" />
<xs:element name="negative" type="xs:boolean" />
<xs:element name="seconds" type="xs:double" />
<xs:element name="years" type="xs:int" />
</xs:sequence>
*</xs:complexType>