找到类型为Ljavax / xml / bind / annotation / XmlAccessType; .FIELD的数据

时间:2013-12-28 18:54:12

标签: java xml annotations

我在使用 JAXBContext

进行编组XML时遇到以下问题
JAXBContext jc = JAXBContext.newInstance(Cdata.class);

错误日志:

java.lang.annotation.AnnotationTypeMismatchException: 
 Incorrectly typed data found for annotation element public abstract
 javax.xml.bind.annotation.AccessType javax.xml.bind.annotation.XmlAccessorType.value()
 (Found data of type Ljavax/xml/bind/annotation/XmlAccessType;.FIELD)

0 个答案:

没有答案