How are classes loaded when using BundleLoader.addDynamicImportPackage() ? [message #101767] |
Wed, 21 November 2007 04:59  |
Eclipse User |
|
|
|
Originally posted by: richard256.gmx.de
I am using BundleLoader.addDynamicImportPackage for on-the-fly
instrumentation of classes. I observed, that it is sufficient to give the
packages of classes directly being refered of the instrumented classes in
the target bundle. Classes refered by the classes in the dynamically
imported package are found themselves.
Since I am not familiar enough with the OSGi specification (is it specified
behaviour at all?), I would like to know how the inported package is linked
into the target bundle? Will the classes be loaded anew by the class loader
of the target bundle? From the behaviour in my prototype I would assume that
the answer is no, and the classloader of the imported package is queried for
class definitions. Is that the desired behaviour? Or just by chance? And
;-), most important, can I rely on that behaviour?
Thanks
Richard
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.27502 seconds