Launches applications from a "main" method and Java applets