|
Re: How to customize the date type of xsd in EMF [message #426373 is a reply to message #426371] |
Wed, 31 December 2008 12:25 |
Ed Merks Messages: 33146 Registered: July 2009 |
Senior Member |
|
|
Tracy,
Comments below.
tracy wrote:
> Hi, Ed
> Thanks for your reply. I need to clarify my case.
> Now our product used EMF for data persistence, when the xsd contains
> date type in xsd, then we use Resource.save() to serialize the data to
> xml file. If the data transferred in web, as the instanceClass for
> date is javax/xml/datatype/XMLGregorianCalendar, which is not
> serialized. so the machine in web will not get the correct info from
> the machine stored data. So we need to fix this issue. I investigate
> this case and find that we need to change the instanceClass for date
> type. If the bug you mentioned
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=246418 has fixed the
> serialize issue. Do you mean If I use the ecore 2.5.0, the data will
> be serialized when invoke Resource.save().
Resource.save does not use java.io.Serializable, so is unaffected by
whether the data type supports that. Of course there could be some
detail you're leaving out, but normally an XMLResourceImpl is used and
what's saved is an XML representation. That XML can be sent anywhere
else and read back in. There really must be some detail you're leaving
out...
> Do I need do additional effort to support my case? Thanks a lot!
With the 2.5.0 runtime, our XMLDuration implementation class does
support java.io.Serializable directly...
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.03362 seconds