Moves the OpenState class into it's own file.