Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » refresh not working properly
refresh not working properly [message #335102] Mon, 23 March 2009 11:03 Go to next message
Youmm P. is currently offline Youmm P.Friend
Messages: 140
Registered: July 2009
Senior Member
Hello,

After creating programmaticaly a new project in the workspace, I refresh
the workspace with this code:

project.getWorkspace ().getRoot ().refreshLocal
(IWorkspaceRoot.DEPTH_INFINITE, monitor);

However, sometimes, the Project Explorer View doesn't show the new project.

What should I do? Is it possible to trigger a resource change event and
how? shoudn't this be done automatically when I build the project, since
I also do project.build (IncrementalProjectBuilder.FULL_BUILD, monitor) ?

Thanks in advance for your help!
Re: refresh not working properly [message #335136 is a reply to message #335102] Tue, 24 March 2009 06:10 Go to previous messageGo to next message
Prakash G.R. is currently offline Prakash G.R.Friend
Messages: 621
Registered: July 2009
Senior Member
You don't need to refresh the entire workspace. IProject.refreshLocal()
should do.
BTW, how are you creating the project? Are you calling a IProject.create()?

- Prakash
--

http://blog.eclipse-tips.com
Re: refresh not working properly [message #335165 is a reply to message #335136] Tue, 24 March 2009 16:11 Go to previous messageGo to next message
Youmm P. is currently offline Youmm P.Friend
Messages: 140
Registered: July 2009
Senior Member
Prakash G.R. wrote:
> You don't need to refresh the entire workspace. IProject.refreshLocal()
> should do.
> BTW, how are you creating the project? Are you calling a IProject.create()?
I'm creating the project with create() and I tried doing a refreshLocal
on the workspace AND on the project. Even with these two refreshed,
sometimes (one time out of 30 or 50 times roughly) the new project does
not appear in the Project Explorer.
Re: refresh not working properly [message #335188 is a reply to message #335165] Wed, 25 March 2009 14:38 Go to previous messageGo to next message
Prakash G.R. is currently offline Prakash G.R.Friend
Messages: 621
Registered: July 2009
Senior Member
> sometimes (one time out of 30 or 50 times roughly) the new project does
> not appear in the Project Explorer.

Sounds like a bug to me.

- Prakash
--
http://blog.eclipse-tips.com
Re: refresh not working properly [message #335259 is a reply to message #335102] Fri, 27 March 2009 22:35 Go to previous message
Eclipse UserFriend
Originally posted by: francis.oaklandsoftware.com

If you are using Eclipse before 3.5 this could be a bug, and it's likely
that it's fixed in 3.5M6, if you can reproduce this problem in 3.5M6
please file a bug report.

On Mon, 23 Mar 2009 04:03:24 -0700, Youmm P. <kototamo@gmail.com> wrote:

> Hello,
>
> After creating programmaticaly a new project in the workspace, I refresh
> the workspace with this code:
>
> project.getWorkspace ().getRoot ().refreshLocal
> (IWorkspaceRoot.DEPTH_INFINITE, monitor);
>
> However, sometimes, the Project Explorer View doesn't show the new
> project.
>
> What should I do? Is it possible to trigger a resource change event and
> how? shoudn't this be done automatically when I build the project, since
> I also do project.build (IncrementalProjectBuilder.FULL_BUILD,
> monitor) ?
>
> Thanks in advance for your help!



--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
Previous Topic:Project clean event?
Next Topic:Problem with 3.5 rewriting eclipse.ini
Goto Forum:
  


Current Time: Fri Apr 26 22:15:07 GMT 2024

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

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

Back to the top