Well, there isn't a workaround for this as it's not a bug. An empty element is not valid for any Decimal or Date type or anything like that. Thus, it SHOULD throw an exception. What are you expecting it to do?
Dan On Wednesday 07 July 2010 12:31:52 pm Bryan-8 wrote: > Using CXF 2.1.10, If the response XML contains empty tag for a Date Type > e.g. <EndDate/> or Decimal Type <Amount/> > > JAXB throws a Unmarshalling Error > > java.lang.NumberFormatException > at java.math.BigDecimal.<init>(BigDecimal.java:457) > at java.math.BigDecimal.<init>(BigDecimal.java:647) > at > com.sun.xml.bind.DatatypeConverterImpl._parseDecimal(DatatypeConverterImpl. > java:169) at > com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl$23.parse(RuntimeB > uiltinLeafInfoImpl.java:749) at > com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl$23.parse(RuntimeB > uiltinLeafInfoImpl.java:747) > > > after debugging CXF, i think the code that's causing this problem is > um.setEventHandler(null); in DataReaderImpl. > > Is there a workaround for this? -- Daniel Kulp [email protected] http://dankulp.com/blog
