Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Model Instances of a UML2 metamodel extension does not work for me [XMI coding problems]
Model Instances of a UML2 metamodel extension does not work for me [XMI coding problems] [message #414290] Mon, 29 October 2007 18:38 Go to next message
Eclipse UserFriend
Originally posted by: reda.bendraou.gmail.com

Hello every one!!
I have a metamodel which is the result of UML2 metamodel extension by emof
classes (ecore encolsed to this email). I can generate the genmodel and even
the edit and editor stuff. I a seperate workbench, I can create model
instances of this metamodel (thanks to the wizard). However, once I close
and save the file (containing the model instance) it is impossible for me to
open it again. there is many errors due inresolved xmi references. Is anyone
has an idea about this bug and how can I manage it? Do I have to choose
explicitly a kind of xmi coding? Thanks in advance for your help!! Herein, a
sample of these errors (see jpeg joined file for the complete list) :

org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$1Diagnos ticWrappedException:
org.eclipse.emf.ecore.xmi.UnresolvedReferenceException: Unresolved reference
'//@processElements.0/From_Start_to_CallBehavior'.
(platform:/resource/uml4spminstances/simpleProcessExample.um l4spm, 4, 112)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.handleDe mandLoadException(ResourceSetImpl.java:316)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLo adHelper(ResourceSetImpl.java:275)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResou rce(ResourceSetImpl.java:398)
at uml4spm.presentation.Uml4spmEditor.createModel(Uml4spmEditor .java:954)
........
...........

Thanks!!
r.




Re: Model Instances of a UML2 metamodel extension does not work for me [XMI coding problems] [message #414293 is a reply to message #414290] Mon, 29 October 2007 18:57 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33136
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------090803080601080103000002
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Reda,

Given that you are doing a heavy weight extension of UML2 you likely
will need to look carefully at their documentation for doing that.
Perhaps it's as simple as registering the same resource as is registered
for *.uml resource to be used for your model. Just looking a the
fragment path

//@processElements.0/From_Start_to_CallBehavior

It seems likely that EModelElementImpl's specialized implementation of
eURIFragmentSegment is kicking in when perhaps that's not what you want.

I suspect that heavy weight extensions of UML should generally be
avoided and that you should be trying to get by with profiles...


Reda Bendraou wrote:
> Hello every one!!
> I have a metamodel which is the result of UML2 metamodel extension by emof
> classes (ecore encolsed to this email). I can generate the genmodel and even
> the edit and editor stuff. I a seperate workbench, I can create model
> instances of this metamodel (thanks to the wizard). However, once I close
> and save the file (containing the model instance) it is impossible for me to
> open it again. there is many errors due inresolved xmi references. Is anyone
> has an idea about this bug and how can I manage it? Do I have to choose
> explicitly a kind of xmi coding? Thanks in advance for your help!! Herein, a
> sample of these errors (see jpeg joined file for the complete list) :
>
> org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$1Diagnos ticWrappedException:
> org.eclipse.emf.ecore.xmi.UnresolvedReferenceException: Unresolved reference
> '//@processElements.0/From_Start_to_CallBehavior'.
> (platform:/resource/uml4spminstances/simpleProcessExample.um l4spm, 4, 112)
> at
> org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.handleDe mandLoadException(ResourceSetImpl.java:316)
> at
> org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLo adHelper(ResourceSetImpl.java:275)
> at
> org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResou rce(ResourceSetImpl.java:398)
> at uml4spm.presentation.Uml4spmEditor.createModel(Uml4spmEditor .java:954)
> ........
> ...........
>
> Thanks!!
> r.
>
>
>


--------------090803080601080103000002
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Reda,<br>
<br>
Given that you are doing a heavy weight extension of UML2 you likely
will need to look carefully at their documentation for doing that.&nbsp;&nbsp;
Perhaps it's as simple as registering the same resource as is
registered for *.uml resource to be used for your model.&nbsp; Just looking
a the fragment path<br>
<blockquote>
<pre wrap="">//@processElements.0/From_Start_to_CallBehavior</pre >
</blockquote>
It seems likely that EModelElementImpl's specialized implementation of
eURIFragmentSegment is kicking in when perhaps that's not what you want.<br>
<br>
I suspect that heavy weight extensions of UML should generally be
avoided and that you should be trying to get by with profiles...<br>
<br>
<br>
Reda Bendraou wrote:
<blockquote cite="mid:fg59cm$n8c$1@build.eclipse.org" type="cite">
<pre wrap="">Hello every one!!
I have a metamodel which is the result of UML2 metamodel extension by emof
classes (ecore encolsed to this email). I can generate the genmodel and even
the edit and editor stuff. I a seperate workbench, I can create model
instances of this metamodel (thanks to the wizard). However, once I close
and save the file (containing the model instance) it is impossible for me to
open it again. there is many errors due inresolved xmi references. Is anyone
has an idea about this bug and how can I manage it? Do I have to choose
explicitly a kind of xmi coding? Thanks in advance for your help!! Herein, a
sample of these errors (see jpeg joined file for the complete list) :

org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$1Diagnos ticWrappedException:
org.eclipse.emf.ecore.xmi.UnresolvedReferenceException: Unresolved reference
'//@processElements.0/From_Start_to_CallBehavior'.
(platform:/resource/uml4spminstances/simpleProcessExample.um l4spm, 4, 112)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.handleDe mandLoadException(ResourceSetImpl.java:316)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLo adHelper(ResourceSetImpl.java:275)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResou rce(ResourceSetImpl.java:398)
at uml4spm.presentation.Uml4spmEditor.createModel(Uml4spmEditor .java:954)
.........
............

Thanks!!
r.


</pre>
</blockquote>
<br>
</body>
</html>

--------------090803080601080103000002--


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:Java model *in* ecore?
Next Topic:[Announce] Mint component proposal
Goto Forum:
  


Current Time: Fri Apr 19 05:27:34 GMT 2024

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

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

Back to the top