refactoring, view implementation