move functionalities from executable to Application class