aikar / TaskChain

TaskChain Control Flow framework. Helps facilitate running tasks on an application's "Main Thread" (such as a game), and tasks off the main (async).
https://taskchain.emc.gs
MIT License
202 stars 41 forks source link

executeFuture support #15

Open aikar opened 6 years ago

aikar commented 6 years ago

An alternative to .execute(), that returns a future that is resolved with the last returned value (if the last is generic/doesnt return, Object is used and null)

If .executeFuture is used, the chain should note that, and any uncaught exception should bubble to the pending future.