Refactoring new oo code