[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [equinox-dev] Re: Suggestion: add Eclipse-UnpackBundle: to manifest
- From: "Alex Blewitt" <alex.blewitt@xxxxxxxxx>
- Date: Wed, 29 Mar 2006 00:10:55 +0100
- Delivered-to: email@example.com
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=PFjEpCEx8HYIl9W6O0bISQ8GxS4anc6CKHdLEwPbNRIOxpEkSq1zoUWU7SPkzx8NmYjtbTE3HzUW2LRjYG+nTNhy6hJ7TkbBGSEZQBe0hfHRld+5Z7MClrLw9kta3zI05oLHJg4GoJUyz/LLHVZPTmUXIkgkoS2CuEklCWDnb7w=
> 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.