Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [ve-dev] Need to get plug-in path

Hi Rich,

Thanks!

>>> RLK >>>
By the way, you can do this for now, but we intend to provide helpers for
this because we need to do the same sort of thing too.

One more thing, was there some reason you couldn't use the standard
RegisteredClassPathContainerInitializer that we provide for developers? This
would take care of the classpath for you. The only reason you need to
provide your own classpath container initializer is if you need to provide
different set of jars depending on the configuration. If it is always the
same set of jars, then the RegisteredClassPathContainerInitializer would be
better for you to use.

>>>>>


Besides a jar that we ship as part of the plug-in, we need to include ULC
libs that are dependent on the ULC installation dir on the user's machine.

So, in Add Library, we have a custom entry ULC_LIBRARY and custom dialog for
getting the ULC installation dir. And hence our own class path initializer.

Thanks and regards,

Janak

"Janak Mulani" <janak.mulani@xxxxxxxxx>
Sent by: ve-dev-bounces@xxxxxxxxxxx
10/03/2005 12:35 PM Please respond to
Discussions people developing code for the Visual Editor project

To"Discussions people developing code for the Visual Editor project"
<ve-dev@xxxxxxxxxxx>
cc
SubjectRE: [ve-dev] Need to get plug-in path







Hi,

Sorry for being bit hasty in posting!

I found a soultion.

I can use IPath.makeAbsolute() before passing to newLibraryEntry().

Please confirm if this is ok or there is another way.

Thanks and regards,

Janak

> -----Original Message-----
> From: ve-dev-bounces@xxxxxxxxxxx [mailto:ve-dev-bounces@xxxxxxxxxxx]On
> Behalf Of Janak Mulani
> Sent: Monday, October 03, 2005 6:00 PM
> To: ve-Dev@Eclipse. Org
> Subject: [ve-dev] Need to get plug-in path
>
>
> Hi,
>
> I need to include a jar file from our plugin in the classpath Container.
>
> For this I need to know the absolute path of our plugin on the user's
> machine. How can I do it?
>
>
> In Eclipse 3.0.x the following worked:
>
> Bundle bundle = Platform.getBundle("plugin name");
> bundlePaths = bundle.getLocation().split("@");
> path = new Path(bundlePaths[1] + "my.jar");
> JavaCore.newLibraryEntry(path,null,null)
>
> In Eclipse 3.1:
> The above does not work because getLocation90 returns relative
> path and not
> absolute path. The reason is that
> ConfigurationActivator.getBudlesToInstall() is now storing relative paths
> instead of absolute path.
>
> newLibraryEntry(path, null, null) expects abs path, so its
> assertion fails.
>

_______________________________________________
ve-dev mailing list
ve-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/ve-dev



Back to the top