move implementation to separate class