Book a Demo

Author Topic: Is DiagramLinks.ConnectorID in VBScript read/write  (Read 12100 times)

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8107
  • Karma: +119/-20
    • View Profile
Re: Is DiagramLinks.ConnectorID in VBScript read/write
« Reply #15 on: March 12, 2019, 09:33:31 am »
I can't see ANY rationale for explicitly using the current behaviour in ANY existing user code.
Copying the style properties from one diagramlink to another.

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +257/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Is DiagramLinks.ConnectorID in VBScript read/write
« Reply #16 on: March 12, 2019, 10:33:23 am »
I can't see ANY rationale for explicitly using the current behaviour in ANY existing user code.
Copying the style properties from one diagramlink to another.
No, I meant with respect to the two IDs.  Obviously, copying properties doesn't require changing the ID, merely synchronising the properties.

Our Use Case is similar.   In our case, it's moving the properties from one connector to another (new) connector.  We want to discard the previous connector from the diagram.

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8107
  • Karma: +119/-20
    • View Profile
Re: Is DiagramLinks.ConnectorID in VBScript read/write
« Reply #17 on: March 12, 2019, 10:53:49 am »
I was providing an example of how an existing client could be using the existing behavior. Currently anyone can copy the complete style from one diagram link to another by changing the connector id and/or diagram id and calling update.

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +257/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Is DiagramLinks.ConnectorID in VBScript read/write
« Reply #18 on: March 14, 2019, 11:33:58 am »
I was providing an example of how an existing client could be using the existing behaviour. Currently, anyone can copy the complete style from one diagram link to another by changing the connector id and/or diagram id and calling update.
I was thinking about this and this isn't an example of a Use Case, its an example of an Abuse Case.

It violates so many data integrity concepts...  It smacks to me of the "Streaker's Defence" - "It seemed like a good idea at the time, your honour..."

The table is defined with Instance_ID as the primary key and the tuple DiagramID, ConnectorID is NOT defined as a unique key.  So there is no concept of the DiagramID, ConnectorID defining a link.  (In fact, we've noticed occasional duplicate link errors when running the integrity checker - so they might be caused by the faulty API also).

The API needs to respect these rules.  Otherwise, we as users can't expect anything to work.  As it is we've discovered we issued a specific instruction, only to find the API decided to do something else...

"It's a bug, "

Paolo
« Last Edit: March 14, 2019, 11:37:33 am by Paolo F Cantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Is DiagramLinks.ConnectorID in VBScript read/write
« Reply #19 on: March 14, 2019, 05:31:12 pm »
My experience with Sparx is just that there's no point in discussing things like that with them. "James," (seems a fit for the partner of  since I don't know her) "the discussion is futile".

q.

P.S. Oh what a coincidence that this post was my 10^4th.
« Last Edit: March 14, 2019, 05:35:21 pm by qwerty »