... refactoring almost done ...