views:

34

answers:

0

In a normal java application its possible to print the content of the classpath with:

String ss = System.getProperty("java.class.path");
System.out.println(ss);

But how do I print the classpath of an OSGI bundle created using the eclipse PDE wizard? In the activator its possible to get the current bundle like:

public void start(BundleContext context) throws Exception { super.start(context); plugin = this;

Bundle b  = context.getBundle();
 // java doc: This bundle's class loader is not used to search for entries. 
b.findEntries(path, filePattern, recurse)

But the javadoc says that the findEntries does NOT use the class loader. Is there any simple way to see/prints what is on the current bundle's classpath?