I am writing Plugin for some Application. Lets suppose that Application hava library dependency of libA-1.0 and my plugin has similar dependency of libA-2.0. There are different in versions and are not compatible each other (i.e. they have different api method signatures).
How to prevent my Plugin from loading classes from libA-1.0 (or how to force it to use classes from libA.2.0)?
Is there any way to do this not writing custom classloader and not using forName, loadClassDefinition calls?
The similar problem occurs when you put some libraries to *.war archive and they do not load becouse web containter has "the same" libraries on classpath.
Thaks for any help.
Regards, Paweł