Hi,
I am using axis 2.0. I have facing some issues with the datetime handling of
axis. It looks like in axis, the xsd:dateTime map to java.util.Calendar.
I am generating stubs with wsdl2java. A class called DateTimeType is generated
by axis based on my wsdl. Here is my schema definition for the DateTimeType.
xs:complexType name="DateTimeType">
<xs:simpleContent>
<xs:extension base="xs:dateTime">
<xs:attribute fixed="DateTime" name="type" type="xs:string"
use="required"/>
<xs:attribute name="mandatory" type="xs:boolean" use="optional"/>
<xs:attribute name="readonly" type="xs:boolean" use="optional"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
It looks like axis generated the following code to deseralize the DateTime.
java.util.Calendar cal =
(java.util.Calendar) new
org.apache.axis.encoding.ser.CalendarDeserializer(
java.lang.String.class,
org.apache.axis.Constants.XSD_STRING).makeValue(_value);
Everytime when the server sends the date, it has the format
2007-06-24T00:14:14+00:00 but when the date passes through axis the datetime
field value changes to 2007-06-24T00:14:14.000Z with a Z in the tail. My server
does not understand this format and reports a SOAP fault.
Is there any way to change this?
Regards,
Suresh Koya