Refactoring and creating classes based on Builder pattern.