Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [Xcore] Using non EMF classes in operations
[Xcore] Using non EMF classes in operations [message #987388] Mon, 26 November 2012 12:01 Go to next message
Jan Rosczak is currently offline Jan RosczakFriend
Messages: 53
Registered: July 2009
Location: Hamburg, Germany
Member
Hi,

I am trying to write operations in Xcore that use classes not defined in an ecore model, such as the Java collection classes or any other non primitiv class, as parameter or return value.

The error I've got is:
A generic type in this context must refer to a classifier or a type parameter

Should this be doable and Xcore currently does not support this or is this simply against the philosophy of Xcore/EMF?

Thanks for helping
Jan

Update:
I re-read the Xcore wiki and found the answer: datatype. But still, it seems a little inconvient to have to define a datatype just to be able to use a Java class as a return type for a method. For any other features it is understandable.

[Updated on: Mon, 26 November 2012 13:24]

Report message to a moderator

Re: [Xcore] Using non EMF classes in operations [message #987461 is a reply to message #987388] Mon, 26 November 2012 17:11 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33108
Registered: July 2009
Senior Member
Jan,

You must define EDataType (type Foo wraps Bar) for any types you want to
use in operations.

On 26/11/2012 1:01 PM, Jan Rosczak wrote:
> Hi,
>
> I am trying to write operations in Xcore that use classes not defined
> in an ecore model, such as the Java collection classes or any other
> non primitiv class, as parameter or return value.
>
> The error I've got is:
> A generic type in this context must refer to a classifier or a type
> parameter
>
> Should this be doable and Xcore currently does not support this or is
> this simply against the philosophy of Xcore/EMF?
>
> Thanks for helping
> Jan


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:Querying EMF model with Xpath
Next Topic:[CDO Hibernate Store] Unable to instantiate default tuplizer
Goto Forum:
  


Current Time: Tue Mar 19 10:55:04 GMT 2024

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

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

Back to the top