Refactoring factor classes.