Improvement on the main class.