MCPcopy Create free account
hub / github.com/traneio/future / rescue

Method rescue

future-java/src/main/java/io/trane/future/Future.java:496–496  ·  view source on GitHub ↗

If this future completes with an exception, applies the provided rescue function and flattens the result. Note that it's possible to return a Future.exception from f if the exception can't be recovered. @param f the function to be executed. @return a future with the result of f.

(Function<Throwable, ? extends Future<T>> f)

Source from the content-addressed store, hash-verified

494 * @return a future with the result of f.
495 */
496 Future<T> rescue(Function<Throwable, ? extends Future<T>> f);
497
498 /**
499 * Creates a future that will be completed with the interrupt exception if an

Callers 8

rescueMethod · 0.65
rescueInterruptMethod · 0.65
genMethod · 0.65
rescueMethod · 0.65
rescueExceptionMethod · 0.65
rescueMethod · 0.65
rescueMethod · 0.65
applyMethod · 0.65

Calls

no outgoing calls

Tested by 7

rescueMethod · 0.52
rescueInterruptMethod · 0.52
genMethod · 0.52
rescueMethod · 0.52
rescueExceptionMethod · 0.52
rescueMethod · 0.52
rescueMethod · 0.52