1

Possible Duplicate:
java.util.Date to XMLGregorianCalendar

I have a Java method with a parameter from the type XMLGregorianCalendar, but I don't know how to set Date/Time:

XMLGregorianCalendar startDateTime = ???

Thank you very much, for helping...

4

1 に答える 1

0
import javax.xml.datatype.DatatypeFactory;
// ...
XMLGregorianCalendar xc = DatatypeFactory.newInstance().newXMLGregorianCalendar(
    int year,
    int month,
    int day,
    int hour,
    int minute,
    int second,
    int millisecond,
    int timezone)

のその他のバージョンがありnewXMLGregorianCalendar()ますnewXMLGregorianCalendar(GregorianCalendar cal)

于 2012-11-21T20:19:21.580 に答える