class is refactored