public void interrupt() { Selector activeSelector = currentSelector; if (activeSelector != null) { activeSelector.wakeup(); } BlockingIO.Condition iowait = blockingIO; if (iowait != null) { iowait.cancel(); } BlockingTask task = currentBlockingTask; if (task != null) { task.wakeup(); } } private volatile BlockingIO.Condition blockingIO = null;
public void interrupt() { Selector activeSelector = currentSelector; if (activeSelector != null) { activeSelector.wakeup(); } BlockingIO.Condition iowait = blockingIO; if (iowait != null) { iowait.cancel(); } BlockingTask task = currentBlockingTask; if (task != null) { task.wakeup(); } } private volatile BlockingIO.Condition blockingIO = null;
@SuppressWarnings("deprecated") public synchronized void interrupt() { setInterrupt(); Selector activeSelector = currentSelector; if (activeSelector != null) { activeSelector.wakeup(); } BlockingIO.Condition iowait = blockingIO; if (iowait != null) { iowait.cancel(); } Unblocker task = this.unblockFunc; if (task != null) { task.wakeup(this, unblockArg); } // deprecated { BlockingTask t = currentBlockingTask; if (t != null) { t.wakeup(); } } // If this thread is sleeping or stopped, wake it notify(); }
@SuppressWarnings("deprecated") public synchronized void interrupt() { setInterrupt(); Selector activeSelector = currentSelector; if (activeSelector != null) { activeSelector.wakeup(); } BlockingIO.Condition iowait = blockingIO; if (iowait != null) { iowait.cancel(); } Unblocker task = this.unblockFunc; if (task != null) { task.wakeup(this, unblockArg); } // deprecated { BlockingTask t = currentBlockingTask; if (t != null) { t.wakeup(); } } // If this thread is sleeping or stopped, wake it notify(); }