Hi Ron
One way is to serialize the date in form of a String
ie. Make methods like
String getStringDate(){.....here make the formatted string out of the
date and let it get marshalled}
setStringDate(String date){.....here convert the formatted string to
date and get the date object back}
Hope that helps
Manish
-----Original Message-----
From: Corcuera,Ron [mailto:[EMAIL PROTECTED]
Sent: Thursday, 16 October 2003 6:55 AM
To: [EMAIL PROTECTED]
Subject: [castor-dev] Help with the way Marshaller formats a date field
I've recently started using the Source Code generator. When I use the
Marshaller to serialize the Java Object to XML, the Marshaller formats
the
date fields to "2003-10-15T16:42:52.853-04:00" by default with the time
zone
at the end. We, on the other hand need it in the format
"2003-10-15T16:42:52.853Z" where Z denotes UTC. We could also just drop
the
Z so that it is in the format "2003-10-15T16:42:52.853". I have not
found a
way, yet, to instruct the Marshaller to format the date in any specific
way
other than the default. Is there some easy way to specify what format
the
Marshaller will use to format the date?
Thank you.
-------------------
Ron Corcuera
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev