Refactoring the classes.