Raises an interrupt. @param ex the interrupt exception.
(final Throwable ex)
| 361 | * @param ex the interrupt exception. |
| 362 | */ |
| 363 | @SuppressWarnings("unchecked") |
| 364 | @Override |
| 365 | public final void raise(final Throwable ex) { |
| 366 | InterruptHandler interruptHandler; |
| 367 | final Object curr = state; |
| 368 | if (curr instanceof SatisfiedFuture) // Done |
| 369 | return; |
| 370 | else if (curr instanceof Promise && !(curr instanceof Continuation)) // Linked |
| 371 | ((Promise<T>) curr).raise(ex); |
| 372 | else if (curr instanceof LinkedContinuation) |
| 373 | ((LinkedContinuation<?, T>) curr).raise(ex); |
| 374 | else if ((interruptHandler = getInterruptHandler()) != null) |
| 375 | interruptHandler.raise(ex); |
| 376 | } |
| 377 | |
| 378 | @Override |
| 379 | public Future<T> interruptible() { |
nothing calls this directly
no test coverage detected