javafx.application.Application: how does it works?