Hi.
>>https://jaxb.dev.java.net/guide/Migrating_JAXB_2_0_applications_to_JavaSE_6.html#Using_JAXB_2_1_with_JavaSE_6
>
> This IS a very advanced approach....if you can pull it off, that'd be cool.
> i'm getting grief for putting things in endorsed.
I've struggled with classloaders for a few hours. I did not manage.
The main problem is that the XJC2Mojo by itself imports and uses a lot
of JAXB/XJC classes. Therefore most of these classes are already
loaded by the time the mojo starts doing anything. All the classloader
tricks don't help anymore - classes are already loaded.
I've made a bit of progress by isolating the JAXB/XJC specific code
into another class and calling this by reflection. But still I end up
with VerifyErrors and further errors which a due to the fact that
XJC2Mojo and the XJC2MojoDeletate ("another" class) are loaded by
different classloaders.
I still see few possibilities to implement this, but I don't have time now.
Bye.
/lexi