|
Re: how to show EClass,EEnum and EDataType in ecore digram? [message #757858 is a reply to message #756960] |
Wed, 16 November 2011 10:58   |
Eclipse User |
|
|
|
Sohrab,
These are non-containment references, so I assume you'd need to show an
EClassifier in the diagram so you can draw a link. You could do that by
loading a *.ecore resource in the outline view and then dragging
classifiers onto the diagram. Keep in mind that an EEnum is an
EEDataType so EEnum instances can be used in both your dataTypes feature
and your enums feature. Maybe you should have just a single classifiers
feature of type EClassifier...
On 15/11/2011 6:50 PM, sohrab wrote:
> Hello,
>
> I use this annotated java interfaces for my metamodel, and create new
> ecore diagram, but my model's box is empty. How I can add EClass,
> EEnum and EDataType to my diagram?
>
>
> /**
> * * @model */
> public interface eXInput {
> /**
> * * @model
> */
> EList<EDataType> getDataTypes();
> /**
> * * @model
> */
> EList<EEnum> getEnums();
> /**
> * * @model
> */
> EList<EClass> getClasses();
>
> }
>
>
> what I see in ecore diagram:
> www.jpg-upload.com/images/491empty_box.jpg
> Thanks
>
|
|
|
|
Re: how to show EClass,EEnum and EDataType in ecore digram? [message #881822 is a reply to message #760104] |
Tue, 05 June 2012 10:08  |
Eclipse User |
|
|
|
Hi,
I have the same need as Sohrab, namely I'd like to show Ecore elements on my diagram. I have an ecore model with a class having a reference to an EClassifier:
//in OCLinEcore:
property type : ecore::EClassifier[1] { !ordered,!unique };
//in XMI
<eStructuralFeatures xsi:type="ecore:EReference" name="type" ordered="false" unique="false"
lowerBound="1" eType="ecore:EClass <ecore namespace>//EClassifier"/>
I generated an ecorediag file from my model, but this reference to EClassifier does not appear. I tried to load the Ecore metamodel by using "Load resource" from the contextual menu, but it is not possible to browse registered packages. I also tried to create a shortcut, but I can only select a model element from my workspace.
How can I make EClassifier appear on my diagram, so that the connections between my elements and EClassifier are shown?
Thanks,
Luc
|
|
|
Powered by
FUDForum. Page generated in 0.03164 seconds