coffeemachine
state pattern applied