Created
October 22, 2014 16:41
-
-
Save guigarage/cc7af84f21c6020dd64d to your computer and use it in GitHub Desktop.
Background thread DataFX way - ProcessChain
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ProcessChain.create(). | |
addRunnableInPlatformThread(() -> blockUI()). | |
addSupplierInExecutor(() -> loadFromServer()). | |
addConsumerInPlatformThread(d -> updateUI(d)). | |
onException(e -> handleException(e)). | |
withFinal(() -> unblockUI()). | |
run(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment