refactoring use interface