public class InterruptionChecker extends Object
| Constructor and Description |
|---|
InterruptionChecker() |
| Modifier and Type | Method and Description |
|---|---|
void |
check()
Check if this thread or any other thread that shares this InterruptionChecker instance has been interrupted
or has thrown an exception, and if so, throw InterruptedException.
|
boolean |
checkAndReturn()
Check if this thread or any other thread that shares this InterruptionChecker instance has been interrupted
or has thrown an exception, and if so, return true, else return false.
|
public boolean checkAndReturn()
public void check()
throws InterruptedException,
ExecutionException
Copyright © 2016. All rights reserved.