I am trying to generate .java files from XSD files using JAXB. I have two xsd schemas, Base.xsd and Area.xsd. Area.xsd imports Base.xsd. I have been able to create java files for each of the schemas separately, but that results in duplicate java files for the Base.xsd. I tried to solve this problem by creating an episode file for Base.xsd using the command:
xjc -d out -episode base.episode Base.xsd
This worked fine and created the episode file as expected. Next I attempted to create the java files from each of the schemas:
xjc -d ...\src\main\java Base.xsd -p mypackage.base
xjc -d ...\src\main\java Area.xsd -p mypackage.area -extension -b base.episode
The java files for Base.xsd were created successfully, however no files were created for Area.xsd (including the Area-specific classes). I have spent a lot of time looking into this issue, and it seems like it should work as expected.
Is this anything noticeably wrong with what I am doing? Please advise me if there is anything you would recommend changing.
Thanks in advance.