added diagrams for state pattern