문제

I was wondering how can I define my own datatypes within a metamodel created using EMF Ecore ?

The goal is to have a class that may contain many attribute. Each attribute has one Datatype.

The problem I am facing now is when I want to set the attribute datatype [in a model which is conforme to my metamodel ] in the Property View (Eclipse EMF), I get an empty list.

I want something similar to when adding an EAttribute , you get the choice between different Etype (EString, EBoolean,...).

I appreciate any help.

Thank you.

도움이 되었습니까?

해결책

You can add EDataType instances on the same level as EClasses, and they can refer to any kind of Java object. However, be careful that only very simple serialization is available for these objects.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top