views:

535

answers:

2

Hello

I generate Java classes from my XSD schema file using XJC command line tool. The ObjectFactory class generates incomplete content. It generates creation methods without JAXBElement<Type> createType decoration.

What may be the reason of this? Regards Dominik

A: 

Do you have elements in your schema, or just types? This is usually the reason.

David Rabinowitz
+2  A: 

Only some types in a JAXB2 XJC-generated binding need JAXBElement wrappers. Those types that have the @XMLRootElement annotation do not need the wrapper, and so the object factory does not generate one.

skaffman