lot of refactorizations