public static void runInFX ( Runnable doRun ) { if ( Platform . isFxApplicationThread ( ) ) { doRun . run ( ) ; return ; } Platform . runLater ( doRun ) ; }
This method is used to run a specified Runnable in the FX Application thread it returns before the task finished execution