Book a Demo

Author Topic: Classes, Ports and Interfaces - is this really correct?  (Read 10236 times)

stereotype

  • EA User
  • **
  • Posts: 28
  • Karma: +0/-0
    • View Profile
Classes, Ports and Interfaces - is this really correct?
« on: January 30, 2020, 05:48:22 am »
I thought that I understood at least the basics but apparently not. Or? I did the following in EA 15:

Create a class ("Class1")
Create another class ("Class2")
Add a port to Class2 ("PortA")
Right click on PortA, select New Child Element, Required Interface to add a required interface to PortA ("RequiredInterface1")

Add a property (of Class2) to Class1 (PartX:Class2)
Right click on the property PartX:Class2, select Features - Interaction Points (PortA is shown) and check PortA => PortA is shown in the diagram (on PartX:Class2) as I expected.
Right click on PortA in PartX:Class2 and select Features - All Features => no features are shown?!

Question number 1: Why isn't RequiredInterface1 shown here??

Since RequiredInterface1 didn't show up on PortA in PartX:Class2 I tried the following:
Right click on PortA in PartX:Class2 and select New Child Element, Required Interface to add a required interface to PortA on PartX:Class2 =>
PortA in PartX:Class2 now gets an interface "RequiredInterface2" (still no "RequiredInterface1").
PortA in Class2 (i.e. the class, not the instance) now have two interfaces ("RequiredInterface1" and "RequiredInterface2")?!

Question number 2: Why was the interface added to the class itself when I added it in an instance of the class??

I would be very grateful if someone could explain this....?

Thanks!