407 Refactoring output class