David,
*Most* frameworks will provide *most* of the JRE APIs as exported
packages. They use profiles to export the right set of packages
depending on the version of JRE in use. But as a bundle developer, you
don't care whether those packages are exported by the system bundle or
anybody else, you just import them in the normal way.
The exception for java.* exception is frankly a bit of a wrinkle. It
comes from a security restriction enforced by the JVM: only the boot
classloader is allowed to define packages starting with java.*. See
the javadoc for ClassLoader.defineClass(). Therefore the bundle
classloader must use parent delegation for those packages rather than
importing them from another bundle.
Still, to reiterate, as a bundle developer you shouldn't have to worry
about these issues. Just follow this simple rule: import ALL packages
used by your bundle except java.*.
Regards,
Neil
On 26 Sep 2008, at 05:39, David Leangen wrote:
However, what is less clear to me is what becomes of javax.*
packages.
All other packages you must Import in the normal fashion.
Ok, then that makes sense. Thanks!
So, in other words, frameworks normally do not provide anything other
than java.* + whatever the user configures, right?
Cheers,
=David.Leangen
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev