Skip to main content



      Home
Home » Eclipse Projects » Equinox » what's the difference between getResource and getEntry in Bundle interface
what's the difference between getResource and getEntry in Bundle interface [message #709554] Wed, 03 August 2011 22:53 Go to next message
Eclipse UserFriend
The fowlloing two methods are defined in org.osgi.framework.Bundle:
URL getResource(String name);
URL getEntry(String path);

So my question is what's the difference between these two methods and what is an "Entry" in a bundle?
Re: what's the difference between getResource and getEntry in Bundle interface [message #709961 is a reply to message #709554] Thu, 04 August 2011 10:33 Go to previous messageGo to next message
Eclipse UserFriend
getResource uses the bundle's class loader to load a resource. This resource could come from imported constraints (Import-Package, Require-Bundle) or from the local bundle classpath.

getEntry only searches the bundles jar files itself and does not consider any constraints or the bundle's class path (Bundle-ClassPath header).

HTH

Tom.
Re: what's the difference between getResource and getEntry in Bundle interface [message #710032 is a reply to message #709961] Thu, 04 August 2011 11:51 Go to previous message
Eclipse UserFriend
Tom,

Thanks very much for the explanation.
Previous Topic:p2 publisher - error message
Next Topic:ClassCastException, totally weird
Goto Forum:
  


Current Time: Tue Sep 02 02:44:47 EDT 2025

Powered by FUDForum. Page generated in 0.04810 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top