Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] Re: Suggestion: add Eclipse-UnpackBundle: to manifest

> You write that nested JARs in a packed bundle are extracted to the
> file system.  Could you elaborate?
>
> For example, where are they extracted, when, and by what layer?

They're performed by either the EclipseClassLoader or the
OSGIBundleClassLoader (or some such names; Jeff will no doubt correct
me :-) Whenever you hit a file that must be accessed as a file
(including native DLLs or other Jars) they are temporarily extracted
to a file on disk such that the handle can be passed to the
appropriate layer (such as System.loadLibrary()). If you look in
configuration/org.eclipse.osgi.bundle/ you'll see a bunch of numbered
directories, and under that, the individual entries that have been
auto-extracted from the Jar. Anything that can't handle a
getResourceAsStream() and just uses getResource() is processed this
way. I seem to recall that there's methods like 'findResource' in
those places, but it's been a while since I've been there so my memory
is somewhat hazy.

Alex.

Back to the top