Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » How to wait for build job?
How to wait for build job? [message #484376] Mon, 07 September 2009 10:03 Go to next message
Velganesh Subramanian is currently offline Velganesh SubramanianFriend
Messages: 69
Registered: July 2009
Member
I have a user job that generates few html files from a given EMF model. My
application is in such a way that the EMF model is not ready until the
build job is complete.

After going through the code for 'Clean...' action (under Project menu), I
found that 'ResourcesPlugin.getWorkspace().getRuleFactory().buildRule() '
is used to check for conflicts. In my isConflicting(), I have

if (rule.getClass() == ResourcesPlugin.getWorkspace().getRuleFactory()
.buildRule().getClass())
return true;

But my job simply proceeds with its file generation logic without waiting
for build to complete. How do I make my job to wait for build job to
complete?
Re: How to wait for build job? [message #484519 is a reply to message #484376] Tue, 08 September 2009 03:49 Go to previous message
Velganesh Subramanian is currently offline Velganesh SubramanianFriend
Messages: 69
Registered: July 2009
Member
I got this snippet from Eclipse FAQ.

IJobManager jobMan = Platform.getJobManager();
Job[] build = jobMan.find(ResourcesPlugin.FAMILY_AUTO_BUILD);
if (build.length == 1)
build[0].join();

Is this the way I need to follow? Can't I detect within scheduling rules?
Previous Topic:PDE Build with Maven Ant
Next Topic:Write own MenuContribution to enable simple ribbon?
Goto Forum:
  


Current Time: Sat Jan 25 23:07:20 GMT 2025

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

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

Back to the top