Author Topic: Sequence diagram: Condition for all lifelines  (Read 4873 times)

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Sequence diagram: Condition for all lifelines
« on: September 18, 2007, 12:26:30 am »
Hi,
i am searching for a way to define a condition for all lifelines at ones (it's a global state). The StateInvariant covers only one lifeline, so I have to resize it to cover more than one lifeline. The problem is, that the XMI-Exporter does not save all covered lifelines (UML says, that a StateInvariant only have one covered lifeline).

Is there an other way to add a condition, that covers all lifelines?

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #1 on: September 18, 2007, 02:03:51 am »
I take it that you mean you want a quick way to establish a set of state invariants, one for each lifeline. This would not invalidate the diagram (according to UML) by creating a single state invariant that applied to more than one lifeline. Is this correct?

David
No, you can't have it!

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #2 on: September 18, 2007, 02:17:35 am »
I don't mean a set of state invariants.
Perhaps, a example helps to demonstrate my prob:
I have three objects for devices, every device having its own states (Ready, Failure, ...). And there is the complete system with all devices and a global state (Global_Ready, ...).

To add the StateInvariant over one lifeline can be missunderstood, a condition over all lifelines would be easier to understand.

Another example:
http://www.item.ntnu.no/fag/SIE5020/MSC_HTML-version/02-03_MSC-Basics/02-03-04-CoregionSubmessage/exercise1.gif
The instances X,Y,Z must be 'Idle', after sending some messages they must be 'Idle' too (for example for test specification).

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #3 on: September 18, 2007, 03:20:54 am »
Quote
i am searching for a way to define a condition for all lifelines at ones (it's a global state). The StateInvariant covers only one lifeline...UML says, that a StateInvariant only have one covered lifeline

It sounds like you need to define something a bit different. You are definitely looking at a 'global' situation, rather than a 'common' one. Offhand, I'm not sure what exactly is needed.

David

PS: I cannot open the page you referenced.
No, you can't have it!

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #4 on: September 18, 2007, 05:06:22 am »
Oh, there is a '*' instead of an 'a' in the link. New correct one:
http://www.item.ntnu.no/fag/SIE5020/MSC_HTML-version/02-03_MSC-Basics/02-03-04-CoregionSubmessage/exercise1.gif

Perhaps, the picture helps you to understand my problem ;-)

PS: The forum seems to replace the first 'a' with an '*'.
« Last Edit: September 18, 2007, 05:07:55 am by MrDX »

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #5 on: September 19, 2007, 09:22:47 pm »
Anyone an idea?

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +54/-3
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #6 on: September 19, 2007, 09:44:07 pm »
Quote
PS: The forum seems to replace the first 'a' with an '*'.

I've fixed that for you. It's the crafty mechanism built into the forums to prevent name calling ;)
The Sparx Team
[email protected]

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #7 on: September 19, 2007, 09:46:22 pm »
Quote
I've fixed that for you. It's the crafty mechanism built into the forums to prevent name calling ;)

Thank you ;)

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +54/-3
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #8 on: September 19, 2007, 09:53:12 pm »
Quote
Anyone an idea?

Is it a Continuation? They have the same notation as a State Invariant but may cover multiple lifelines.
The Sparx Team
[email protected]

MrDX

  • EA User
  • **
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Sequence diagram: Condition for all lifelines
« Reply #9 on: September 19, 2007, 10:01:57 pm »
I think so too, but Enterprise architect can only cover one lifeline (snaps to one of them). The other problem:
Quote
The OMG UML specification (UML Superstructure Specification, v2.0, p. 414) states:
"A Continuation is a syntactic way to define continuations of different branches of an Alternative CombinedFragment. Continuations is intuitively similar to labels representing intermediate points in a flow of control."

The OMG UML specification (UML Superstructure Specification, v2.0, p. 415) also states:
"Continuations have semantics only in connection with Alternative CombinedFragments and (weak) sequencing. If an InteractionOperand of an Alternative CombinedFragment ends in a Continuation with name (say) X, only InteractionFragments starting with the Continuation X (or no continuation at all) can be appended."

=> The UML specification allows continuations only for CombinedFragments.