Refactorings and modularization