UML&OCL Modeling Languages


States' diagrams (statecharts)

Illustration: a coffee machine that accepts a coins 5c, 10c and 20c, and that returns a coffee for 25c.


Statechart (CoffeeMachine' behavior)

As an exercise, represent the scenario with a client that puts 10c then 20c to a coffee machine.


4 - 9