简体   繁体   中英

Generating Pojos from XSD with JAXB while a element and a attribute have the same name

My Sample XSD file is this: http://schemas.opengis.net/gml/3.2.1/geometryPrimitives.xsd

Im using Netbeans 7.3.1 and im trying to generate a Pojo from it but it says :

[ERROR] Property"Rows"is already defined.Use<jaxb:property>to resolve this conflict.
   Line 653 of http://schemas.opengis.net/gml/3.2.1/geometryPrimitives.xsd

i dont understand the JAXB external binding with an .xjb file. Is Netbeans able to build it? Are there any aids from Netbeans to resolve this?

You propably have to tell the XJC compiler to use different names for the attribute and the element, see other question here

JAXB - Property "Value" is already defined. Use <jaxb:property> to resolve this conflict

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM