Thursday, January 3, 2008

JAXB - XJC Task Cannot Resolve '' to a(n) element declaration component

JAXB XJC Task ignores the second import statement in xsds. Hence multiple imports would not get read and hence classes would not be generated. Once the reference of those non-generated classes are invoked, XJC throws "Cannot resolve '' to a(n) element declaration component".

Solution:
1. Pass "-nv" argument to XJC Task
For Ant:

For Maven:

No comments: