boss class refactoring