Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » How To Programmatically Refresh The Workspace After Creating A New Project
How To Programmatically Refresh The Workspace After Creating A New Project [message #336934] Tue, 14 July 2009 15:53 Go to next message
Eclipse User
Originally posted by: runzhou.li.gmail.com

Hi,

I noticed that after creating a project programmatically, the workspace is
not refreshed automatically and therefore causes the project files (that are
created together with the project) not shown without refreshing.

So the question is how to programatically refresh the workspace?

Thank you!

--
Runzhou Li
Re: How To Programmatically Refresh The Workspace After Creating A New Project [message #336935 is a reply to message #336934] Tue, 14 July 2009 18:32 Go to previous messageGo to next message
Ed Merks is currently offline Ed Merks
Messages: 26137
Registered: July 2009
Senior Member
Are you doing all the work within a single WorkspaceModifyOperation?
That would be the best way to ensure there is a single refresh with all
the changes.


Runzhou Li wrote:
> Hi,
>
> I noticed that after creating a project programmatically, the workspace is
> not refreshed automatically and therefore causes the project files (that are
> created together with the project) not shown without refreshing.
>
> So the question is how to programatically refresh the workspace?
>
> Thank you!
>
> --
> Runzhou Li
>
>
>
Re: How To Programmatically Refresh The Workspace After Creating A New Project [message #336947 is a reply to message #336934] Wed, 15 July 2009 13:08 Go to previous messageGo to next message
Prakash G.R. is currently offline Prakash G.R.
Messages: 621
Registered: July 2009
Senior Member
Runzhou Li wrote:

> So the question is how to programatically refresh the workspace?

Does IWorkspaceRoot.refreshLocal() helps?

- Prakash

---
http://blog.eclipse-tips.com
Re: How To Programmatically Refresh The Workspace After Creating A New Project [message #336955 is a reply to message #336947] Wed, 15 July 2009 20:18 Go to previous message
Eclipse User
Originally posted by: runzhou.li.gmail.com

Thanks guys, refreshLocal(IFile) works fine, haven't tried the
WorkspaceModifyOperation thing, will look into that later.

"Prakash G.R." <grprakash@gmail.com> wrote in message
news:h3kkdb$i0a$2@build.eclipse.org...
> Runzhou Li wrote:
>
>> So the question is how to programatically refresh the workspace?
>
> Does IWorkspaceRoot.refreshLocal() helps?
>
> - Prakash
>
> ---
> http://blog.eclipse-tips.com
Previous Topic:Perspectives
Next Topic:How To Programmatically Add Nature And Builders Into A Project
Goto Forum:
  


Current Time: Thu Oct 23 01:45:01 GMT 2014

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

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