Event definitions

93 views
Skip to first unread message

Robert

unread,
May 10, 2013, 12:51:09 PM5/10/13
to yakind...@googlegroups.com
I struggled with this the other day.  I went back to the documentation to check my understanding and I could not figure out what I could be doing wrong.

Eventually I decided to just cut and paste from the documentation to see if that worked so I could slowly change it to what I was doing and see where the problem was.  However the definitions in the documentation do not work either.

Specifically if you create a new statechart and put the following in the specification box (A cut and paste from the documentation).

interface NamedInterface:
in event event1
out event event2

internal:
event localEvent1: integer
local event localEvent2 = NamedInterface.event1 || localEvent1
local event localEvent3 = localEvent2 || 25

I get the following error

Description    Resource    Path    Location    Type
missing EOF at '='    default2.sct    /test    /test/default2.sct    Statechart Diagram problems


Robert

Andreas Mülder

unread,
May 10, 2013, 1:56:06 PM5/10/13
to yakind...@googlegroups.com
Robert,
as Axel already mentioned, this is a feature called derived events that is not supported right now.
The idea is to define an event that is based on a boolean condition:

event limit_exceeded = x > 42

Thanks for the hint, I will update the documentation accordingly.

Best regards,

Andreas

Robert

unread,
May 10, 2013, 4:58:44 PM5/10/13
to yakind...@googlegroups.com
A-ha,

I thought the derived events comments only referred to arbitrary expressions and that events could be logically combined.

Thanks, Andreas
Reply all
Reply to author
Forward
0 new messages