Package com.avpkit.ferry
Interface JNIThreadProxy.Interruptable
-
- Enclosing class:
- JNIThreadProxy
public static interface JNIThreadProxy.Interruptable
Interface that global interrupt handlers should use.- Author:
- aclarke
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanpostInterruptCheck(boolean interruptStatus)Called AFTER native code callsThread.interrupted()and allows the caller to override the returned value if desired.booleanpreInterruptCheck()Called BEFORE native code callsThread.interrupted().
-
-
-
Method Detail
-
preInterruptCheck
boolean preInterruptCheck()
Called BEFORE native code callsThread.interrupted().Please note that this method can be called from any thread and it is the responsibility of the caller to ensure it is thread safe.
- Returns:
- true if the JNIThreadProxy should continue on an call
Thread.interrupted(). false to stop processing now (and tell callers the thread is NOT interrupted).
-
postInterruptCheck
boolean postInterruptCheck(boolean interruptStatus)
Called AFTER native code callsThread.interrupted()and allows the caller to override the returned value if desired.- Parameters:
interruptStatus- The value returned byThread.interrupted()on the current thread- Returns:
- The value you actually want to return to native code. Allows you to override the value returned.
-
-