thurn/defer
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Repository files navigation
Defer is a simple Java library that implements an interface for managing asynchronous operations. It is based on the Promise and Deferred objects from jQuery. Asynchronous functions can return a Promise<Value> to indicate thay will later supply a value or experience an error. The real power of Deferreds is the ability to chain them. Methods like Deferred#then() and Promises.awaitAll() are provided to enable chaining. If any promise in the chain experiences an error, the error will be passed through the chain. In this way, you can make a Promise which wraps several different potentially concurrent asynchronous operations.