[#20] implemented state pattern...