refactor.

extract creating menu method to a class.