Author Topic: Instance of an component?  (Read 3931 times)

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Instance of an component?
« on: October 08, 2007, 01:38:48 am »
Hi,
I created an instance of an component and exported it to XMI 2.1, but I can't find the ownedPort-Association in the UML2-metamodel. The little test szenario looks like this:

The following XMI-Code is generated (without associations):

Code: [Select]
<packagedElement xmi:type="uml:InstanceSpecification" xmi:id="EAID_363FA362_96D3_4421_9D58_803F05EEF70A" name="d2" visibility="public" classifier="EAID_E89BA2F3_9764_43b9_83F0_77B4C46F48D3">
   <ownedPort xmi:type="uml:Port" xmi:id="EAID_20D018ED_0294_4f7f_8C1F_A6C09807380A" name="CAN" visibility="public" aggregation="composite"/>
   <ownedPort xmi:type="uml:Port" xmi:id="EAID_F632B8E9_434C_4c12_A409_38E5E8AB5345" name="FlexRay" visibility="public" aggregation="composite"/>
</packagedElement>

Is it the correct way to model the scenario 'A communicates from his own FlexRay-port over Bus1 with the FlexRay-port of B'?
Are there instances of components in UML2?

Thanks for your help :-)

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Instance of an component?
« Reply #1 on: October 09, 2007, 10:39:06 pm »
No ideas?   :'(

jeshaw2

  • EA User
  • **
  • Posts: 701
  • Karma: +0/-0
  • I'm a Singleton, what pattern are you?
    • View Profile
Re: Instance of an component?
« Reply #2 on: October 10, 2007, 06:04:11 pm »
Quote
Is it the correct way to model the scenario 'A communicates from his own FlexRay-port over Bus1 with the FlexRay-port of B'?
I think you meant Bus2 ?

An interesting question, but I don't have an answer ... yet  ???
Verbal Use Cases aren't worth the paper they are written upon.

jeshaw2

  • EA User
  • **
  • Posts: 701
  • Karma: +0/-0
  • I'm a Singleton, what pattern are you?
    • View Profile
Re: Instance of an component?
« Reply #3 on: October 10, 2007, 06:16:02 pm »
Have you tried using an Assembly connector (ball & socket) rather than an Association link?
Verbal Use Cases aren't worth the paper they are written upon.

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Instance of an component?
« Reply #4 on: October 10, 2007, 09:44:19 pm »
Thank you for answering :-)

The association link isn't the problem. My problem is the ownedPort-tag in XMI. I tried to load the XMI with the Eclipse modeling framework and the UML2 project. After modifying the XMI file (without an component instance), so that EMF can load it, I added a component instance. EMF returns a error like:
"Feature 'ownedPort' not valid".
So, I used the UML specification to search for the ownedPort-Association and I think, that the ownedPort-tag is not correct there (because a InstanceSpecification and its supertypes does not have a ownedPort-Association).

Now, I am confused and hope, that the UML 2 specification allows to connect Ports of component objects.

Do you know what I mean?

PS: Yes, I meant 'Bus2' ;)