-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JAXB spec should be updated to support new JDK8 Date/Time apis #238
Comments
@glassfishrobot Commented |
@glassfishrobot Commented |
@glassfishrobot Commented https://jaxb.java.net/guide/Using_different_datatypes.html https://docs.oracle.com/javase/8/docs/api/javax/xml/bind/DatatypeConverter.html |
@glassfishrobot Commented |
|
@lukasj Is it necessary to modify API to include the "new" JSR-310? package org.acme.foo;
public class ZonedDateTimeAdapter {
public static ZonedDateTime parseDate(String s) {
return DatatypeConverter.parseDate(s).toZonedDateTime();
}
public static String printDate(ZonedDateTime zdt) {
Calendar cal = new GregorianCalendar();
cal.setTime(java.util.Date.from(zdt.toInstant()));
return DatatypeConverter.printDate(cal);
}
} In fact, DatatypeFactory doesn't extend JSR-310 API. Regards, |
@lukasj Regards, |
JAXB spec should be updated to support new JDK8 Date/Time apis
The text was updated successfully, but these errors were encountered: