Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » How to get ICProject out of IProject?
How to get ICProject out of IProject? [message #49471] Mon, 11 November 2002 18:45 Go to next message
Kiran Lingutla is currently offline Kiran LingutlaFriend
Messages: 10
Registered: July 2009
Junior Member
Hi,
Is there a way to get an ICProject object out of an IProject object?
I found a method createCProject in org.eclipse.cdt.core.CCorePlugin but
it returns an IProject and not an ICProject? Isn't this wrong?

Thanks for your help.
-Kiran
Re: How to get ICProject out of IProject? [message #49687 is a reply to message #49471] Tue, 12 November 2002 18:14 Go to previous messageGo to next message
Judy N. Green is currently offline Judy N. GreenFriend
Messages: 149
Registered: July 2009
Senior Member
"Kiran" <klingutla@hotmail.com> wrote in message
news:3DCFFADF.9030701@hotmail.com...
| Hi,
| Is there a way to get an ICProject object out of an IProject object?
| I found a method createCProject in org.eclipse.cdt.core.CCorePlugin but
| it returns an IProject and not an ICProject? Isn't this wrong?

IProject is defined within the Eclipse framework and has no knowledge of
other plugins such as the CDT.
Therefore there is no way to get an ICProject (defined in the CDT) object
out of an IProject (defined in Eclipse Framework) object?

What exactly are you trying to do. There is probably another way to get what
you are looking for.

-Judy

--
Re: How to get ICProject out of IProject? [message #49717 is a reply to message #49687] Tue, 12 November 2002 19:24 Go to previous messageGo to next message
Kiran Lingutla is currently offline Kiran LingutlaFriend
Messages: 10
Registered: July 2009
Junior Member
hi Judy,
Thanks for your reply. In JDT, there is a method JavaCore.create which
takes in IProject and returns IJavaProject. I was wondering if there is
such a method available in CDT.
I need this because my java project might contain some "c" code and to
process those "C" files, I am trying to create an ICProject object out
of an IProject object. I am not expecting to find a method in the
eclipse API to do this but I expect something similar to be in CDT.
As I said earlier, org.eclipse.cdt.core.CCorePlugin.createCProject takes
in IProject but it returns an IProject again instead of ICProject.

Thanks
-Kiran

Judy N. Green wrote:
> "Kiran" <klingutla@hotmail.com> wrote in message
> news:3DCFFADF.9030701@hotmail.com...
> | Hi,
> | Is there a way to get an ICProject object out of an IProject object?
> | I found a method createCProject in org.eclipse.cdt.core.CCorePlugin but
> | it returns an IProject and not an ICProject? Isn't this wrong?
>
> IProject is defined within the Eclipse framework and has no knowledge of
> other plugins such as the CDT.
> Therefore there is no way to get an ICProject (defined in the CDT) object
> out of an IProject (defined in Eclipse Framework) object?
>
> What exactly are you trying to do. There is probably another way to get what
> you are looking for.
>
> -Judy
>
> --
> ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨ ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨
> Judy N. Green Software Engineer
> QNX Software Systems Ltd. www.qnx.com
> ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨ ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨
> |
> | Thanks for your help.
> | -Kiran
> |
>
>
Re: How to get ICProject out of IProject? [message #49745 is a reply to message #49717] Tue, 12 November 2002 19:24 Go to previous messageGo to next message
David Inglis is currently offline David InglisFriend
Messages: 45
Registered: July 2009
Member
Yes, the same exists in CDT. CoreModel.create(IProject).

Kiran wrote:
> hi Judy,
> Thanks for your reply. In JDT, there is a method JavaCore.create which
> takes in IProject and returns IJavaProject. I was wondering if there is
> such a method available in CDT.
> I need this because my java project might contain some "c" code and to
> process those "C" files, I am trying to create an ICProject object out
> of an IProject object. I am not expecting to find a method in the
> eclipse API to do this but I expect something similar to be in CDT.
> As I said earlier, org.eclipse.cdt.core.CCorePlugin.createCProject takes
> in IProject but it returns an IProject again instead of ICProject.
>
> Thanks
> -Kiran
>
> Judy N. Green wrote:
>
>> "Kiran" <klingutla@hotmail.com> wrote in message
>> news:3DCFFADF.9030701@hotmail.com...
>> | Hi,
>> | Is there a way to get an ICProject object out of an IProject object?
>> | I found a method createCProject in org.eclipse.cdt.core.CCorePlugin but
>> | it returns an IProject and not an ICProject? Isn't this wrong?
>>
>> IProject is defined within the Eclipse framework and has no knowledge of
>> other plugins such as the CDT.
>> Therefore there is no way to get an ICProject (defined in the CDT) object
>> out of an IProject (defined in Eclipse Framework) object?
>>
>> What exactly are you trying to do. There is probably another way to
>> get what
>> you are looking for.
>>
>> -Judy
>>
>> --
>> ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨ ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨
>> Judy N. Green Software Engineer
>> QNX Software Systems Ltd. www.qnx.com
>> ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨ ¨¨¨°ºo§oº°¨¨¨¨°ºo§oº°¨¨¨
>> |
>> | Thanks for your help.
>> | -Kiran
>> |
>>
>>
>
Re: How to get ICProject out of IProject? [message #1832269 is a reply to message #49471] Mon, 14 September 2020 20:53 Go to previous message
jan baeyens is currently offline jan baeyensFriend
Messages: 15
Registered: March 2012
Junior Member
Just In case I get here again :-s

ICProject cProject = CoreModel.getDefault().getCModel().getCProject(project.getName());

does the trick

Jantje
Previous Topic:Need help making interface look like C language
Next Topic:use mingw32-make.exe intead of make
Goto Forum:
  


Current Time: Mon Oct 14 21:10:09 GMT 2024

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

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

Back to the top