Base example for state pattern