Author Topic: Connector API - Client and Supplier Connector  (Read 1630 times)

adepreter

  • EA User
  • **
  • Posts: 94
  • Karma: +2/-2
    • View Profile
Connector API - Client and Supplier Connector
« on: December 05, 2016, 03:19:06 am »
Using the connector API (http://www.sparxsystems.com/enterprise_architect_user_guide/13.0/automation/connector2_2.html)

- how can we figure out that the client or supplier is another connector?

- if the client or supplier is a connector, how can we get a reference to that connector? Would the Client/SupplierID then be the ID of a connector?

qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Connector API - Client and Supplier Connector
« Reply #1 on: December 05, 2016, 04:05:22 am »
Client/supplier are always elements, never connectors. What are you trying here?

q.

adepreter

  • EA User
  • **
  • Posts: 94
  • Karma: +2/-2
    • View Profile
Re: Connector API - Client and Supplier Connector
« Reply #2 on: December 05, 2016, 06:15:27 am »
We have detailed connectors that realize summary connectors. This is expressed using a connector to connector realization relationship.

0------0
    / \
     |
     |
0------0

Based on a selected connector (SC), I would like to create a script providing zoom-in/zoom-out behaviour :
- Find "connector to connector" connectors (CCs) starting from the selected connector (SC)
- Find target connectors (TCs) at the other end of each "connector to connector" connector (CC)
- Open diagrams that contain the target connectors (TCs) and select the target connectors

qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Connector API - Client and Supplier Connector
« Reply #3 on: December 05, 2016, 06:59:54 am »
How can you draw such a relation in EA manually?

q.

P.S. Though I seem to remember having seen such a thing, I can't remember where. According to the UML 2.5 specs a Relationship is a specialization of Element and such could be source/target of another connector. However, in Sparx' world, a connector is NOT an element but a 2nd class citizen with different properties. Maybe they have tricked around in V13 to make it possible. But I have no idea how to do that manually.

P.P.S. Found http://sparxsystems.com/enterprise_architect_user_guide/13.0/modeling_tools/conn_to_conn.html I'll have a look.
« Last Edit: December 05, 2016, 07:20:33 am by qwerty »

qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Connector API - Client and Supplier Connector
« Reply #4 on: December 05, 2016, 07:52:31 am »
Back again. What they do is to create elements for the connectors which have a MetaType ProxyConnector. These have a ClassifierID which is the ID of the corresponding connector. Good luck (because this is something they added "just now" and where I have a gut feeling you should not touch it for production until the next say 3 months have passed).

q.

Rich Anderson

  • EA User
  • **
  • Posts: 69
  • Karma: +2/-0
    • View Profile
    • LinkedIn
Re: Connector API - Client and Supplier Connector
« Reply #5 on: June 15, 2018, 11:29:34 am »
Hi There,  Just checking to see whether this has been figured out.  (and I have not been able to find any other posts on this topic)  I have a situation where I have a connector that is connected to a class from the connector and would like to get a reference to it, but cannot seem to figure out how to do so with the API. (Although I can get to the 'ProxyConnector' element from the other side) The diagram where this happens look like this.

https://imgur.com/a/iaWzTLl





Rich Anderson
Urgnt Limited

VKN

  • EA User
  • **
  • Posts: 185
  • Karma: +9/-1
    • View Profile
Re: Connector API - Client and Supplier Connector
« Reply #6 on: June 15, 2018, 12:53:50 pm »
Currently, there is no support added in the API.
When you select a connector that is connected to another connector, a proxy object is displayed on the connector end.
The link from the proxy (object) to the connector is in the t_object.Classifier_Guid.