Book a Demo

Author Topic: statechart  (Read 4159 times)

Danny F

  • EA User
  • **
  • Posts: 60
  • Karma: +0/-0
    • View Profile
statechart
« on: December 19, 2012, 01:49:47 am »
Hi

Can anybody point me to some code that creates/manipulates a statechart (state machine)

specifically I'm not able to relate an existing Trigger(kind=signal) element to a transition(stateflow) in the statechart ???
Also the type (signal) I cannot set ??

Via the user interface one can add multiple triggers, selected from the project browser, to a stateflow.
How can I do this through code ?

thanks in advance





Reg.

Danny

Danny F

  • EA User
  • **
  • Posts: 60
  • Karma: +0/-0
    • View Profile
Re: statechart
« Reply #1 on: December 19, 2012, 09:05:08 pm »
OK - found already this :

The references to the Triggers which are added to the StateFlow are kept in a t_xref row
-> description field contains a comma separated list of GUIDs

follow up question :

Anybody has a routine, code, etc.... how to write such a record ??

dangerous stuff I imagine, but the only way as I see it now.

Thanks
Reg.

Danny

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: statechart
« Reply #2 on: December 19, 2012, 10:15:38 pm »
Undocumented and unsupported but valid as parachute:  
Code: [Select]
Repository.Execute('INSERT INTO t_xref ....')To create the XRefID use any algorithm to create a GUID (there's something inside the Windoze libs or your language specific libs).

q.

Danny F

  • EA User
  • **
  • Posts: 60
  • Karma: +0/-0
    • View Profile
Re: statechart
« Reply #3 on: December 20, 2012, 12:27:52 am »
WORKS  :) 8-)

thanks
Reg.

Danny