Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » Tag elements of a sequence diagram in an emx file (UML2)
Tag elements of a sequence diagram in an emx file (UML2) [message #1805198] Tue, 09 April 2019 19:12 Go to next message
Amine Haddaji is currently offline Amine HaddajiFriend
Messages: 5
Registered: April 2019
Junior Member
Hi ,
I have a .emx file containing a sequence diagram and a class diagram. The sequence diagram represents traces that i got while executing a J2EE application.
I want to know what the different tags represent. For example : <ownedOperation> , <ownedParameter> , <packagedElement xsi:type="uml:ReceiveOperationEvent"> , <packagedElement xsi:type="uml:Class"> ...
I attached an emx file and included a little sample here.
To give you guys an idea of what I'm trying to do, i'm trying to parse the sequence diagram using java to transform it into a JSON file in order to create a call graph.



example :
<packagedElement xsi:type="uml:SendOperationEvent" name="getLocale284"/>
  <packagedElement xsi:type="uml:ReceiveOperationEvent" name="getScreens287" operation="//com.sun.j2ee.blueprints.petstore.control.web.ScreenFlowManager/getScreens.1"/>
  <packagedElement xsi:type="uml:SendOperationEvent" name="getScreens288" operation="//com.sun.j2ee.blueprints.petstore.control.web.ScreenFlowManager/getScreens.1"/>
  <packagedElement xsi:type="uml:ReceiveOperationEvent" name="getScreens292"/>
  <packagedElement xsi:type="uml:SendOperationEvent" name="getScreens293"/>
  <packagedElement xsi:type="uml:Class" name="com.sun.j2ee.blueprints.petstore.control.web.Screen">
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
    <ownedOperation name="getParameter">
      <ownedParameter name="arg1" type="//java.lang.String"/>
      <ownedParameter type="//com.sun.j2ee.blueprints.petstore.control.web.Parameter" direction="return"/>
    </ownedOperation>
</packagedElement>
  • Attachment: example.emx
    (Size: 3.07MB, Downloaded 58 times)
Re: Tag elements of a sequence diagram in an emx file (UML2) [message #1805391 is a reply to message #1805198] Sat, 13 April 2019 08:32 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 6937
Registered: July 2009
Senior Member
Hi

Your *.emx file appears to be a 'standard' UML 2.3 file using the Eclipse UML form of the UML metamodel. You should be able to load that using the corresponding Eclipse (MDT) UML2 tooling and get an equivalent EMF Java model instance. No need for you to write a parser.

However UML 2.3 was a long time ago. UML 2.4 removed the MessageOccurrenceSpecification::event association used extensively by your model, so it fails to load on the current UML 2.5 support.

The migration guide [1] refers to [2] which explains that OccurrenceSpecification::event was removed in UML 2.4 8 years ago since events were generally unnecessary and just required artificial bloated pseudo-events.

You should therefore eliminate and use a modern Eclipse, or live with them and continue to use the seriously vintage Eclipse, UML and Java.

Either way, your file should load without trouble.

Regards

Ed Willink

[1] https://wiki.eclipse.org/MDT/UML2/UML2_4.0_Migration_Guide#Ecore_.2F_UML_Conversion

[2] https://www.omg.org/issues/issue14629.txt
Re: Tag elements of a sequence diagram in an emx file (UML2) [message #1805398 is a reply to message #1805391] Sat, 13 April 2019 16:30 Go to previous messageGo to next message
Amine Haddaji is currently offline Amine HaddajiFriend
Messages: 5
Registered: April 2019
Junior Member
Thanks for the clarification. I have managed to upgrade the emx file to 2.4.1 using IBM Rational software architecture. and i have started reading the documentation corresponding to that version of UML. And about the Eclipse (MDT) UML2 , not writing a parser would absolutely save me a lot of time. I will definitely look into that. do you have any tips on where to start? Thanks.
Re: Tag elements of a sequence diagram in an emx file (UML2) [message #1805400 is a reply to message #1805398] Sat, 13 April 2019 19:53 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 6937
Registered: July 2009
Senior Member
hi

With the tutorials.

Regards

Ed Willink
Previous Topic:Get all class attributes, including those from association ends
Next Topic:How to load and use MARTE profile
Goto Forum:
  


Current Time: Sat Dec 05 15:49:24 GMT 2020

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

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

Back to the top