Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » IncrementalProjectBuilder (newbie)
IncrementalProjectBuilder (newbie) [message #249675] Fri, 04 June 2004 14:21 Go to next message
Eclipse UserFriend
Originally posted by: karypid.inf.uth.nospam.gr

Hi all,

How can I add a nature I created to _already_ existing Java projects?

From the docs I only found programmatic ways to associate the nature with
the project, when the project is created.

The proble is that my nature is supposed to be applied to JDT projects,
which are created by the JDT wizard. I don't want to change the JDT code.

Is there a way to tell Eclipse to "attach" a nature to a project, once it
has been created?

--
In theory, there is no difference between theory and practice.
In practice, there is. -- Yogi Berra.

Alexandros Karypidis
University of Thessaly
Computer & Communications Engineering dept.
Re: IncrementalProjectBuilder (newbie) [message #250066 is a reply to message #249675] Mon, 07 June 2004 09:20 Go to previous message
Eclipse UserFriend
According to the "Java Developer's Guide to Eclipse" you need to do the
following:
get the descriptions of a Projet (projet.getDescription())
you can now retrieve the old natures using getNatureIds on the
description. Create a new array with the old natures and you own.
set the newNatures using setNatureIds, and finally set the description
using setDescription on the project.
hope that helps.
// florian

Alexandros Karypidis wrote:
> Hi all,
>
> How can I add a nature I created to _already_ existing Java projects?
>
> From the docs I only found programmatic ways to associate the nature with
> the project, when the project is created.
>
> The proble is that my nature is supposed to be applied to JDT projects,
> which are created by the JDT wizard. I don't want to change the JDT code.
>
> Is there a way to tell Eclipse to "attach" a nature to a project, once it
> has been created?
>
Previous Topic:Beyond CVS
Next Topic:Help plugins and Eclipse 3.0
Goto Forum:
  


Current Time: Fri May 09 02:01:28 EDT 2025

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

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

Back to the top