I did not see anyone answer this. 

F2 does not need to import the package from F1. Since they are both loaded 
by the same classloader, they have access to all of the classes in the 
host bundle+attached fragments.

If you do put in the export and import for P1, based upon my reading of 
section 3.14 of the spec, F1 will add an export for the package P1 and F2 
will add an import for the package P1. The framework will then choose to 
either export the package or import the package. So either F1 and F2 will 
use P1 from F1 if the package is exported, or they will use P1 from some 
other bundle with a matching export.

BJ Hargrave
Senior Technical Staff Member, IBM
OSGi Fellow and CTO of the OSGi Alliance
[EMAIL PROTECTED]

office: +1 407 849 9117
mobile: +1 386 848 3788




"Jeremy Volkman" <[EMAIL PROTECTED]> 
Sent by: [EMAIL PROTECTED]
11/09/2006 11:47 AM
Please respond to
OSGi Developer Mail List <[email protected]>


To
[email protected]
cc

Subject
[osgi-dev] Quick fragment question






In R4, I have two fragments, F1 and F2, attached to the same host
bundle.  F1 exports package P1 that the host has no knowledge of.  In
this situation, should F2 be able to import package P1 from F1?

Thanks,
Jeremy Volkman
_______________________________________________
OSGi Developer Mail List
[email protected]
http://bundles.osgi.org/mailman/listinfo/osgi-dev


_______________________________________________
OSGi Developer Mail List
[email protected]
http://www2.osgi.org/mailman/listinfo/osgi-dev

Reply via email to