Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » How to add jars and folders to classpath
How to add jars and folders to classpath [message #325655] Mon, 25 February 2008 12:37 Go to next message
Eclipse UserFriend
Originally posted by: automatic.javalobby.org

Hi,

We are developing a plugin, which requires jars and folders containing java files to be added to classpath. We thought of using preferences. However no idea how to modify classpath at runtime.

Does this require writing your own classloader or eclipse does provide some API.

Could you please point out, how to add jars or folders to classpath at runtime. Thanking you in advance.

Regards,
dheer
Re: How to add jars and folders to classpath [message #325711 is a reply to message #325655] Mon, 25 February 2008 18:22 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wharley.bea.com

"reindheer" <automatic@javalobby.org> wrote in message
news:8402208.14671203943056988.JavaMail.root@cp1.dzone.com...
> Hi,
>
> We are developing a plugin, which requires jars and folders containing
> java files to be added to classpath. We thought of using preferences.
> However no idea how to modify classpath at runtime.
>
> Does this require writing your own classloader or eclipse does provide
> some API.
>
> Could you please point out, how to add jars or folders to classpath at
> runtime. Thanking you in advance.

By "at runtime" do you mean after the application has already started, i.e.,
too late to change the classpath that you load the application with? If so,
then yes, AFAIK you will need to use your own classloader. You don't
actually need to write the classloader yourself, you can just use an
URLClassLoader.
Re: How to add jars and folders to classpath [message #325787 is a reply to message #325711] Wed, 27 February 2008 04:08 Go to previous message
Eclipse UserFriend
Originally posted by: automatic.javalobby.org

Hi Walter,

Thank you for replying. I will try your suggestion and post the results here.

Thank You,
dheer
Previous Topic:Detached view question
Next Topic:key binding in editor does not work in eclipse 3.4
Goto Forum:
  


Current Time: Thu Aug 15 19:41:43 GMT 2024

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

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

Back to the top