Update Application.java to be able to run GUI or Shell.