refactoring to make interfaces clean