Method
map
(final Function<? super T, ? extends R> f)
Source from the content-addressed store, hash-verified
| 18 | } |
| 19 | |
| 20 | @Override |
| 21 | public final <R> Future<R> map(final Function<? super T, ? extends R> f) { |
| 22 | try { |
| 23 | return new ValueFuture<>(f.apply(value)); |
| 24 | } catch (final Throwable ex) { |
| 25 | return new ExceptionFuture<>(ex); |
| 26 | } |
| 27 | } |
| 28 | |
| 29 | @Override |
| 30 | public final <R> Future<R> flatMap(final Function<? super T, ? extends Future<R>> f) { |
Callers
nothing calls this directly
Tested by
no test coverage detected