| 78 | } |
| 79 | |
| 80 | final class AsyncPromise<T> extends Promise<T> implements Runnable { |
| 81 | private final Supplier<T> s; |
| 82 | |
| 83 | public AsyncPromise(final Supplier<T> s) { |
| 84 | super(); |
| 85 | this.s = s; |
| 86 | } |
| 87 | |
| 88 | @Override |
| 89 | public final void run() { |
| 90 | try { |
| 91 | setValue(s.get()); |
| 92 | } catch (final Throwable error) { |
| 93 | NonFatalException.verify(error); |
| 94 | setException(error); |
| 95 | } |
| 96 | } |
| 97 | } |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…