java - Import a package from a specific bundle when it is available also in another -
there 2 bundles (a , b) exports package a.b.c , b third party bundle. used dependency other modules has imports a.b.c. these modules should package bundle , not b. without excluding a.b.c package b using <export-package>
possible provide workaround bundle restrict modules refer package itself?
in module uses has a,b,c other places, place exclude inside dependency tag pom.
so, i'm confusing myself letters if project bob uses dependency don't want bob pull a,b , c because has elsewhere then, in pom.xml bob, within tag you'd use , exclusion.
<exclusions> <exclusion> <groupid>sample.a</groupid> <!-- exclude project-a project-a --> <artifactid>project-a</artifactid> </exclusion> </exclusions>
check out full example @ 'exclude dependencies'
Comments
Post a Comment