Stimulus

StarUML

Stimulus

Top  Previous  Next

Semantics

A Stimulus is a communication between two Instances that conveys information with the expectation that action will ensue. A Stimulus will cause an Operation to be invoked, raise a Signal, or cause an Instance to be created or destroyed.

Procedure for creating stimulus

In order to create stimulus,

1.Click [Toolbox] -> [Sequence] -> [Stimulus] button.

ch05_317

2.Drag from one object, and drop to the other(object or lifeline) in the [main window] in outgoing direction.

ch05_318

3.Stimulus quick dialog is opened. Enter the stimulus name at the quick dialog and press [Enter] key.

ch05_319

4.Finally, a stimulus is created as follows.

ch05_320

Procedure for using operation in class as stimulus

If classifier property of receiver(object) of stimulus is assigned and you want to assign operation to stimulus,

1.Double-click stimulus
2.Click ch05_321 button at the quick dialog.

ch05_322

3.Select operation on the [Select an operation] dialog, and click [OK] button.

ch05_323

4.New stimulus mapped to class's operation is added as follows.

ch05_324

Procedure for creating operation of class from object

To create operation of class as stimulus's receiver from object and assign it to stimulus,

1.Double-click stimulus, click ch05_325 button at the quick dialog.

ch05_326

2.Enter new operation name to be created, and click [OK] button.

ch05_327

3.New operation is added to the class and text is filled at the quick dialog (This procedure is valid when there exists assigned class.). Press [Enter] key.

ch05_328 ch05_329

4.See [model explorer] to confirm creation of new operation.

ch05_330

Procedure for creating previous stimulus of current stimulus by using shortcut creation syntax

In order to create previous stimulus to current stimulus,

1.Double-click a stimulus, or select a stimulus and press [Enter] key.

ch05_331

2.At the quick dialog, After "~>" string("<~" for incoming stimulus), enter target object name and stimulus name.

ch05_332

3.Press [Enter] key, and then new object and stimulus are created and arranged above selected stimulus.

ch05_333

Procedure for creating next stimulus to current stimulus by using shortcut creation syntax

In order to create next stimulus to selected stimulus,

1.Double-click a stimulus, or select a stimulus and press [Enter] key.

ch05_334

2.At the quick dialog, After "_>" string("<_" for incoming stimulus), enter target object name and stimulus name.

ch05_335

3.Press [Enter] key, and then new object and stimulus are created and arranged next to selected stimulus.

ch05_336

Procedure for creating sub stimulus by using shortcut creation syntax

In order to create a sub stimulus of selected stimulus,

1.Double-click a stimulus, or select a stimulus and press [Enter] key.

ch05_337

2.At the quick dialog, After "->" string("<-" for incoming stimulus), enter target object name and sub stimulus name.

ch05_338

3.Press [Enter] key, and then new object and stimulus are created and arranged on the bottom of selected stimulus's activation.

ch05_339

Procedure for reconnecting to another object

In order to reconnect stimulus to another object,

1.Click the end of stimulus.

ch05_340

2.Drag the end of stimulus and drop it to another object.

ch05_341

3.Then stimulus will be connected to another object.

ch05_342

Procedure for changing ActionKind of stimulus

The [ActionKind] property of stimulus should be assigned to one of five sort as following. To change [ActionKind] property, select stimulus and select the [ActionKind] property on the properties window.

ActionKind

Shape

CALL

ch05_343

SEND

ch05_344

RETURN

ch05_345

CREATE

ch05_346

DESTROY

ch05_347