I'm attempting to use the 3.7 RCP Report Designer in a project. I've developed
a series of plugins to access a legacy database. For a demo, I wanted to use
a Scripted Data Source/Set, but the scripts don't have access to the bundles.
Is there a solution? I've googled and searched the forums, but haven't seen
anything that appeared to help.
You should be able to use the runtime classes to locate a plugin that is already in the runtime:
I have done this in the past like.
mybundle = Packages.org.eclipse.core.runtime.Platform.getBundle("org.eclipse.birt.report.viewer");
furl = FileLocator.find(mybundle, new Path("/birt/webcontent"), null);
myfolder = FileLocator.toFileURL(furl).getPath();
mc = mybundle.loadClass( "org.eclipse.birt.report.viewer.utilities.WebViewer");
mi = mc.newInstance();
xyz = mi.getCurrentWebApp().getName();