title: xsd:datetime and XmlGregorianCalendar causes NullPointerException
body: <p>The following works:</p>
  
  <pre><code>public Date getDate() {
      return date;
  }
  </code></pre>
  
  <p>and produces something like:</p>
  
  <pre><code>&lt;date&gt;2010-03-23T17:43:50.879Z&lt;/date&gt;
  </code></pre>
  
  <p>And I can use an XmlGregorianCalendar to return xsd:date or xsd:time types fine:</p>
  
  <pre><code>@XmlSchemaType(name="date")
  public XmlGregorianCalendar getDate() {
      return date;
  }
  </code></pre>
  
  <p>which produces something like:</p>
  
  <pre><code>&lt;date&gt;2010-03-23&lt;/date&gt;
  </code></pre>
  
  <p>But trying to return xsd:datetime like so:</p>
  
  <pre><code>@XmlSchemaType(name="datetime")
  public XmlGregorianCalendar getDate() {
       return date;
  }
  </code></pre>
  
  <p>Causes this stack trace:</p>
  
  <pre><code>java.lang.NullPointerException
      at com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl.checkXmlGregorianCalendarFieldRef(RuntimeBuiltinLeafInfoImpl.java:864)
      at com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl.access$200(RuntimeBuiltinLeafInfoImpl.java:111)
      at com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl$13.print(RuntimeBuiltinLeafInfoImpl.java:536)
  ...snip...
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
      at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
      at java.lang.Thread.run(Thread.java:619)
  </code></pre>
  
  <p>Which doesn't mention my code at all.</p>
  
  <p>I'm using tomcat 6.0.24, java 1.6.0_16-b01</p>