Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic Rhapsody (steve huntington)
Decrease font size
Increase font size
Topic Title: Stub State Connectors
Topic Summary:
Created On: 11-Dec-2006 10:29
Status: Read Only
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
 11-Dec-2006 10:29
User is offline View Users Profile Print this message


Leonid Ryzhyk

Posts: 10
Joined: 27-Sep-2006

Hi,

It appears that Rhapsody does not generate code for labels on outgoing transitions from stub state connectors. For example, on the attached statechart, the doSomething() call does not appear in the generated code. The only workaround I could come up with is to insert a condition connector between the stub connector and the doSomething transition; however this introduces additional clutter to the statechart.

Does anyone know the reason for such a limitation and how to to deal with it?

Leonid

stub.jpg
stub.jpg  (14 KB)

Report this to a Moderator Report this to a Moderator
 13-Dec-2006 08:48
User is offline View Users Profile Print this message


Ian Turner

Posts: 25
Joined: 3-Feb-2006

Hi Leonid,

there are a couple of alternatives you could try:

1. Place the doSomething() call in the exit action for the state.
2. Place the doSomething() call on the exit transition of the sub-statechart.

Both place the call in the same place in the code. The first "hides" the call so if visibility of the call is required, I would use the second option.

Hope this helps,

Regards,

Ian
Report this to a Moderator Report this to a Moderator
 13-Dec-2006 09:04
User is offline View Users Profile Print this message


Matthew Thomas

Posts: 35
Joined: 18-Jun-2007

Hi Leonid

Ian's advice is sound.

Like you, I would also expect your initial approach to work. Have you ruled out the possibility that the diagram properties are set to show labels? If so, then I think you are observing a Rhapsody defect. If so, in what version, and have you filed a defect report?

Very best regards

Matthew

-------------------------
-----------------------
Matthew Thomas
Panasonic Manufacturing UK Ltd
Report this to a Moderator Report this to a Moderator
 17-Dec-2006 09:23
User is offline View Users Profile Print this message


Leonid Ryzhyk

Posts: 10
Joined: 27-Sep-2006

[QUOTE=iturner@ferranti-technologies.co.uk]Hi Leonid,

there are a couple of alternatives you could try:

1. Place the doSomething() call in the exit action for the state.
2. Place the doSomething() call on the exit transition of the sub-statechart.

Both place the call in the same place in the code. The first "hides" the call so if visibility of the call is required, I would use the second option.

Hope this helps,

Regards,

Ian[/QUOTE]

Hi Ian,

Thanks for your advice! The first option works well for the simple example from my post. However, if the sub-statechart has more than one exit points and I want to perform different actions for different exit points, then a single exit action does not help.

The problem with the second option is that it would break the modularity of the statechart: the doSomething() action belongs to the external statechart and placing it inside the sub-statechart would affect understandibility and evolvability of the statechart.

Leonid
Report this to a Moderator Report this to a Moderator
 17-Dec-2006 09:32
User is offline View Users Profile Print this message


Leonid Ryzhyk

Posts: 10
Joined: 27-Sep-2006

[QUOTE=matthew.thomas@eu.panasonic.com]Hi Leonid

Ian's advice is sound.

Like you, I would also expect your initial approach to work. Have you ruled out the possibility that the diagram properties are set to show labels? If so, then I think you are observing a Rhapsody defect. If so, in what version, and have you filed a defect report?

Very best regards

Matthew[/QUOTE]

Hi Matthew,

Yes, the diagram properties are correct ("display name"), and if I introduce a dummy conditional connector between the disable_adapter state and the doSomething() action, then Rhapsody generates correct code.

I'm using Rhapsody 7.0 MR1. I haven't filed a defect report yet -- I wanted to seek the community advice first.

Leonid
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic Rhapsody forum.
There are currently 1 users logged in.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.