Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Buckminster dev » How can I see if Resolution is from WS or TP?
How can I see if Resolution is from WS or TP? [message #15567] Wed, 23 April 2008 23:08 Go to next message
Henrik Lindberg is currently offline Henrik Lindberg
Messages: 2500
Registered: July 2009
Senior Member
Hi,
when getting Resolutions and presenting them in the new Component
Explorer View, I would like to separate the components into two major
groups, those that are in my workspace, and those in the target platform.

Is there some way to see that by looking at a Resolution?

Regards
- henrik
Re: How can I see if Resolution is from WS or TP? [message #15663 is a reply to message #15567] Thu, 24 April 2008 05:50 Go to previous messageGo to next message
Thomas Hallgren is currently offline Thomas Hallgren
Messages: 3229
Registered: July 2009
Senior Member
Hi Henrik,
Yes there is. The resolution contains provider used and it in turn holds the id of the reader type.
Use the following snippet:

if(IReaderType.ECLIPSE_PLATFORM.equals(resolution.getProvide r().getReaderTypeId()))
{
// This component stems from the target platform
...
}

Henrik Lindberg wrote:
> Hi,
> when getting Resolutions and presenting them in the new Component
> Explorer View, I would like to separate the components into two major
> groups, those that are in my workspace, and those in the target platform.
>
> Is there some way to see that by looking at a Resolution?
>
> Regards
> - henrik
Re: How can I see if Resolution is from WS or TP? [message #16913 is a reply to message #15663] Fri, 25 April 2008 10:10 Go to previous message
Henrik Lindberg is currently offline Henrik Lindberg
Messages: 2500
Registered: July 2009
Senior Member
Thomas Hallgren wrote:
> The resolution contains provider used and it in turn holds
> the id of the reader type. Use the following snippet:
>
> if(IReaderType.ECLIPSE_PLATFORM.equals(resolution.getProvide r().getReaderTypeId()))
> {
> // This component stems from the target platform
> }

Worked like a charm. The Component Explorer now has two top level
folders - one for target platform, and one for workspace.

Checked in.

- henrik
Previous Topic:How can I get the OPML file?
Next Topic:Component Explorer and Component Outline
Goto Forum:
  


Current Time: Fri Oct 31 19:27:38 GMT 2014

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

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