Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Atomic add and configuration of nature
Atomic add and configuration of nature [message #333514] Tue, 16 December 2008 12:55
Damian Philipp is currently offline Damian PhilippFriend
Messages: 30
Registered: July 2009
Member
Hello everyone,

I am (still) working on a plugin that does some custom compilation stuff
on arbitrary projects. Projects to be considered by my plugin are marked
by the addition of a custom nature.

In order to know what to do with a project, my plugin requires a
configuration file. This configuration file does not have a fixed name
and may or may not exist initially. The location of the configuration
file is to be stored as a persistent property on the project resource.

The question is, what would be the correct place to prompt the user for
this file? IProjectNature#configure() is not enough, as that place is
only called when the nature is added programatically. Plus, some of my
code (namely a Project Explorer extension) was run even before
#configure() was called. In cases where the project is created by
importing preconfigured source code (eg. from subversion), this won't work.

I did think about putting checks for the configuration file everywhere.
However I'd rather not loose the simplicity of IProject#hasNature() to
test whether there is something to be done with a project, as there are
most likely going to be some more constraints apart from the presence of
a configuration file in the futute.

So, is there a way to make sure that a nature does never exist without
some additional constraints being met?

Regards
Damian
Previous Topic:Multiple Column Edits on a Tree Viewer
Next Topic:IStatus not found at runtime
Goto Forum:
  


Current Time: Fri Apr 26 12:34:46 GMT 2024

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

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

Back to the top