Main class: creates necessary objects, injects dependencies and calls run.