Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » How do I inherit from an EDataType
How do I inherit from an EDataType [message #423189] Wed, 24 September 2008 14:59 Go to next message
adotor is currently offline adotorFriend
Messages: 46
Registered: July 2009
Member
Hello,

if I read the ecore-Metamodel right there is currently no
straightforward way to inherit from a EDataType. What do I do if I want
to have an EClass that inherits from an already existing (non-E) class?

Is there a reason why this is prohibited?

Cheers,
Alexander Dotor
Re: How do I inherit from an EDataType [message #423192 is a reply to message #423189] Wed, 24 September 2008 16:09 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 30804
Registered: July 2009
Senior Member
Alexander,

You can use an EClass just like an EDataType in that you can set the
instance class name to some existing Java interface. You can mark the
EClass with isInterface and isAbstract true, so you don't end up with a
generated Impl class that implements that interface. This EClass can
then be used as a super type for your modeled classes.


Alexander Dotor wrote:
> Hello,
>
> if I read the ecore-Metamodel right there is currently no
> straightforward way to inherit from a EDataType. What do I do if I
> want to have an EClass that inherits from an already existing (non-E)
> class?
>
> Is there a reason why this is prohibited?
>
> Cheers,
> Alexander Dotor
Previous Topic:[Databinding] Generic visualization of EObjects
Next Topic:Initialize multivalued attributes/references
Goto Forum:
  


Current Time: Mon Jan 20 07:42:16 GMT 2020

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

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

Back to the top