Author Topic: No connectors shown after XMI import  (Read 314 times)

mse

  • EA User
  • **
  • Posts: 168
  • Karma: +1/-0
    • View Profile
No connectors shown after XMI import
« on: July 14, 2020, 01:18:55 am »
I took a simple composite structure class with two parts, connected to one another via ports. I export this with XMI 2.5.1 and remove EA extensions and diagrams.

I import the same file just to see what happens and while everything imports, when I reconstruct the diagram, the connector is not there. If I check the links tab of the port properties however, I see there is a link to the other port. How do I get these links to display on the diagram again?
« Last Edit: July 15, 2020, 05:03:27 pm by mse »

RoyC

  • EA Administrator
  • EA Practitioner
  • *****
  • Posts: 1272
  • Karma: +18/-4
  • Read The Help!
    • View Profile
Best Regards, Roy

mse

  • EA User
  • **
  • Posts: 168
  • Karma: +1/-0
    • View Profile
Re: XMI import does not import the connectors in composite structure.
« Reply #2 on: July 14, 2020, 04:53:12 pm »
I read that one several times before posting  :D just to make sure I didn't miss something. WHen I try that, I get a context menu, but no option for showing the relation.

However, one thing I noticed is that the links do show in the diagram only if I drag and drop the Property TYPES in the diagram. However, that was not my intent. I wanted the links to show within the context of the composite class. This seems to be less a question of XMI now as it is a of properly modeling the composite class but I don't know what else to do differently with such a simple example. Below are the two exports. I would prefer the one without the EA extensions.

Here is the simple example without EA information:

Code: [Select]
<?xml version="1.0" encoding="windows-1252"?>
<xmi:XMI xmlns:uml="http://www.omg.org/spec/UML/20131001" xmlns:xmi="http://www.omg.org/spec/XMI/20131001" xmlns:umldi="http://www.omg.org/spec/UML/20131001/UMLDI" xmlns:dc="http://www.omg.org/spec/UML/20131001/UMLDC" xmlns:thecustomprofile="http://www.sparxsystems.com/profiles/thecustomprofile/1.0">
<xmi:Documentation exporter="Enterprise Architect" exporterVersion="6.5"/>
<uml:Model xmi:type="uml:Model" name="EA_Model">
<packagedElement xmi:type="uml:Package" xmi:id="EAPK_FA4BB56F_1716_41dc_B9BE_50A96A33C6A2" name="Package1">
<packagedElement xmi:type="uml:Class" xmi:id="EAID_383DF4CF_24DB_4931_93AB_EC9A03699647" name="Class1">
<ownedAttribute xmi:type="uml:Property" xmi:id="EAID_A06A1867_E4D2_4436_8C42_460A43098B43" name="itsClass2" aggregation="composite" isUnique="false">
<type xmi:idref="EAID_3F6CAA9B_4811_4fed_87FE_59CA69FBD673"/>
<qualifier xmi:type="uml:Port" xmi:id="EAID_48E2ACF8_ECCD_4eef_BC9F_4B50E8B0EDC4" name="Port1" aggregation="composite"/>
</ownedAttribute>
<ownedAttribute xmi:type="uml:Property" xmi:id="EAID_9850E9F3_0C74_4141_AE8C_33018A07EF2A" name="itsClass3" aggregation="composite" isUnique="false">
<type xmi:idref="EAID_B35A9E7B_53DA_4109_88C4_412247B23655"/>
<qualifier xmi:type="uml:Port" xmi:id="EAID_1C54214D_1700_4f39_A391_E1BCEB486954" name="Port1" aggregation="composite"/>
</ownedAttribute>
<ownedConnector xmi:type="uml:Connector" xmi:id="EAID_94E549E6_E3AC_4e52_ABAF_CB6AF63CCDAF" name="Connector1">
<end xmi:type="uml:ConnectorEnd" xmi:id="EAID_SC000000_E3AC_4e52_ABAF_CB6AF63CCDAF" role="EAID_0132A1B7_EB2E_44e6_899F_BE05B2FE0BB8"/>
<end xmi:type="uml:ConnectorEnd" xmi:id="EAID_DS000000_E3AC_4e52_ABAF_CB6AF63CCDAF" role="EAID_8C80E19A_60B2_4638_AEF1_4DE4A7A63411"/>
</ownedConnector>
</packagedElement>
<packagedElement xmi:type="uml:Package" xmi:id="EAPK_B9444DC7_0420_4814_9EEE_9BEE3A6503EE" name="Package1">
<packagedElement xmi:type="uml:Class" xmi:id="EAID_3F6CAA9B_4811_4fed_87FE_59CA69FBD673" name="Class2">
<ownedAttribute xmi:type="uml:Port" xmi:id="EAID_8C80E19A_60B2_4638_AEF1_4DE4A7A63411" name="Port1" aggregation="composite"/>
</packagedElement>
<packagedElement xmi:type="uml:Class" xmi:id="EAID_B35A9E7B_53DA_4109_88C4_412247B23655" name="Class3">
<ownedAttribute xmi:type="uml:Port" xmi:id="EAID_0132A1B7_EB2E_44e6_899F_BE05B2FE0BB8" name="Port1" aggregation="composite"/>
</packagedElement>
</packagedElement>
</packagedElement>
<profileApplication xmi:type="uml:ProfileApplication" xmi:id="profileap_thecustomprofile">
<appliedProfile xmi:type="uml:Profile" href="http://www.sparxsystems.com/profiles/thecustomprofile/1.0#thecustomprofile"/>
</profileApplication>
</uml:Model>
<thecustomprofile:rsa_guid base_Class="EAID_383DF4CF_24DB_4931_93AB_EC9A03699647" rsa_guid="_fYDVsMTtEeqjfvlqiadKSA"/>
<thecustomprofile:rsa_guid base_Property="EAID_A06A1867_E4D2_4436_8C42_460A43098B43" rsa_guid="_a5ZjoMTuEeqjfvlqiadKSA"/>
<thecustomprofile:rsa_guid base_Property="EAID_9850E9F3_0C74_4141_AE8C_33018A07EF2A" rsa_guid="_aP56sMTuEeqjfvlqiadKSA"/>
<thecustomprofile:rsa_guid base_Class="EAID_3F6CAA9B_4811_4fed_87FE_59CA69FBD673" rsa_guid="_Ze3fUMTuEeqjfvlqiadKSA"/>
<thecustomprofile:rsa_guid base_Port="EAID_8C80E19A_60B2_4638_AEF1_4DE4A7A63411" rsa_guid="_emI7IMTuEeqjfvlqiadKSA"/>
<thecustomprofile:rsa_guid base_Class="EAID_B35A9E7B_53DA_4109_88C4_412247B23655" rsa_guid="_ZwTNkMTuEeqjfvlqiadKSA"/>
<thecustomprofile:rsa_guid base_Port="EAID_0132A1B7_EB2E_44e6_899F_BE05B2FE0BB8" rsa_guid="_eI7asMTuEeqjfvlqiadKSA"/>
</xmi:XMI>

Boron

  • EA User
  • **
  • Posts: 106
  • Karma: +6/-0
    • View Profile
Re: No connectors shown after XMI import
« Reply #3 on: July 20, 2020, 11:00:32 pm »
The missing connection you are referring to, is a Connector between the ports of the original classes.
Once you create properties (or instances) out of the classes the ports are not the ports of the original classes. And therefore the connector between the "original ports" does not exist between the ports of the property elements.

If you want the ports of the property elements to be connected you have to connect them on your own.
The original connection is not "derived" to the property elements.

mse

  • EA User
  • **
  • Posts: 168
  • Karma: +1/-0
    • View Profile
Re: No connectors shown after XMI import
« Reply #4 on: July 23, 2020, 05:35:23 pm »
Strange, because every time I connect the two ports, it's always between the two ports of the properties and not the original classes. When I export to XMI however, this information is set to a connection between the two ports of the classes, and not the properties. So I'm somewhat stuck here because I have to constantly reconnect the properties every time I export and import to and from XMI.

mse

  • EA User
  • **
  • Posts: 168
  • Karma: +1/-0
    • View Profile
Re: No connectors shown after XMI import
« Reply #5 on: July 27, 2020, 09:43:31 pm »
The question I'm trying to get answered now is: how do I get links between two parts via ports to show up when importing again? How do I set up my model for this?