Behavior : Activity Diagrams - Advanced Topics - Weights

4 important questions on Behavior : Activity Diagrams - Advanced Topics - Weights

An Edge conveys .... (how many) token(s) (either control or object) at a time

an edge conveys only one token (either control or object) at a time

However, in some circumstances, an edge may be declared to require more than one token in order to allow any tokens to pass.

How do we flag such edges?

With a WEIGHT

Example:
weight=nnn where nnn is the number of required tokens or weight=some variable name

What does a Weight edge does?

The edge holds on to the tokens until the required number of tokens arrive—then, they are delivered to the target node.

If the required number of tokens never arrives, the held tokens are lost.
  • Higher grades + faster learning
  • Never study anything twice
  • 100% sure, 100% understanding
Discover Study Smart

When is the Weight feature been used?

The weight feature is typically used after some token source that may generate multiple tokens on its own, such as after a Wait for Time Event or Wait for Message Event.

The question on the page originate from the summary of the following study material:

  • A unique study and practice tool
  • Never study anything twice again
  • Get the grades you hope for
  • 100% sure, 100% understanding
Remember faster, study better. Scientifically proven.
Trustpilot Logo