Searched refs:interrupted (Results 1 - 25 of 54) sorted by relevance

123

/libcore/ojluni/src/main/java/java/nio/channels/spi/
H A DAbstractInterruptibleChannel.java73 * exception or by returning normally. If a thread is interrupted or the
146 private volatile Thread interrupted; field in class:AbstractInterruptibleChannel
164 interrupted = target;
194 * If the thread blocked in the I/O operation was interrupted
200 Thread interrupted = this.interrupted;
201 if (interrupted != null && interrupted == Thread.currentThread()) {
202 interrupted = null;
/libcore/ojluni/src/main/java/sun/nio/ch/
H A DNativeThreadSet.java99 boolean interrupted = false;
104 interrupted = true;
107 if (interrupted)
H A DDevPollArrayWrapper.java224 interrupted = true;
294 boolean interrupted = false; field in class:DevPollArrayWrapper
304 boolean interrupted() { method in class:DevPollArrayWrapper
305 return interrupted;
309 interrupted = false;
H A DEPollArrayWrapper.java261 interrupted = true;
302 private boolean interrupted = false; field in class:EPollArrayWrapper
312 boolean interrupted() { method in class:EPollArrayWrapper
313 return interrupted;
317 interrupted = false;
/libcore/ojluni/src/main/java/sun/misc/
H A DResource.java92 // Even if a thread has been interrupted when loading resources,
96 boolean isInterrupted = Thread.interrupted();
103 Thread.interrupted();
126 Thread.interrupted();
/libcore/jsr166-tests/src/test/java/jsr166/
H A DCountDownLatchTest.java112 * await throws IE if interrupted before counted down
124 assertFalse(Thread.interrupted());
131 assertFalse(Thread.interrupted());
143 * timed await throws IE if interrupted before counted down
155 assertFalse(Thread.interrupted());
162 assertFalse(Thread.interrupted());
H A DExchangerTest.java125 * If one exchanging thread is interrupted, another succeeds.
130 final CountDownLatch interrupted = new CountDownLatch(1);
141 interrupted.await();
146 interrupted.await();
153 interrupted.countDown();
H A DBlockingQueueTest.java234 assertFalse(Thread.interrupted());
241 assertFalse(Thread.interrupted());
270 assertFalse(Thread.interrupted());
280 * take() throws InterruptedException immediately if interrupted
292 assertFalse(Thread.interrupted());
311 assertFalse(Thread.interrupted());
322 * interrupted before waiting
333 assertFalse(Thread.interrupted());
H A DLinkedBlockingDequeTest.java590 assertFalse(Thread.interrupted());
597 assertFalse(Thread.interrupted());
628 assertFalse(Thread.interrupted());
695 assertFalse(Thread.interrupted());
702 assertFalse(Thread.interrupted());
820 assertFalse(Thread.interrupted());
827 assertFalse(Thread.interrupted());
858 assertFalse(Thread.interrupted());
921 assertFalse(Thread.interrupted());
931 * takeFirst() throws InterruptedException immediately if interrupted
[all...]
H A DTimeUnitTest.java334 * timedWait throws InterruptedException when interrupted
350 assertFalse(Thread.interrupted());
359 assertFalse(Thread.interrupted());
369 * timedJoin throws InterruptedException when interrupted
385 assertFalse(Thread.interrupted());
392 assertFalse(Thread.interrupted());
404 * timedSleep throws InterruptedException when interrupted
416 assertFalse(Thread.interrupted());
423 assertFalse(Thread.interrupted());
H A DRecursiveActionTest.java272 Thread.interrupted();
285 Thread.interrupted();
298 Thread.interrupted();
308 Thread.interrupted();
318 Thread.interrupted();
327 Thread.interrupted();
374 assertTrue(Thread.interrupted());
385 assertTrue(Thread.interrupted());
396 assertTrue(Thread.interrupted());
406 assertTrue(Thread.interrupted());
[all...]
H A DPhaserTest.java471 assertFalse(Thread.interrupted());
478 assertFalse(Thread.interrupted());
488 assertFalse(Thread.interrupted());
495 assertFalse(Thread.interrupted());
511 * awaitAdvance continues waiting if interrupted before waiting
526 assertTrue(Thread.interrupted());
536 assertTrue(Thread.interrupted());
540 * awaitAdvance continues waiting if interrupted while waiting
554 assertTrue(Thread.interrupted());
565 assertTrue(Thread.interrupted());
[all...]
H A DSynchronousQueueTest.java137 assertFalse(Thread.interrupted());
144 assertFalse(Thread.interrupted());
173 assertFalse(Thread.interrupted());
273 assertFalse(Thread.interrupted());
280 assertFalse(Thread.interrupted());
/libcore/luni/src/main/java/java/util/concurrent/locks/
H A DAbstractQueuedLongSynchronizer.java368 * Convenience method to park and then check if interrupted.
370 * @return {@code true} if interrupted
374 return Thread.interrupted();
392 * @return {@code true} if interrupted while waiting
396 boolean interrupted = false;
402 return interrupted;
406 interrupted = true;
468 if (Thread.interrupted())
484 boolean interrupted = false;
492 if (interrupted)
[all...]
H A DAbstractQueuedSynchronizer.java835 * Convenience method to park and then check if interrupted.
837 * @return {@code true} if interrupted
841 return Thread.interrupted();
859 * @return {@code true} if interrupted while waiting
864 boolean interrupted = false;
870 return interrupted;
874 interrupted = true;
936 if (Thread.interrupted())
952 boolean interrupted = false;
960 if (interrupted)
[all...]
H A DStampedLock.java339 * given time and the current thread has not been interrupted.
347 * @throws InterruptedException if the current thread is interrupted
353 if (!Thread.interrupted()) {
369 * until available or the current thread is interrupted.
374 * @throws InterruptedException if the current thread is interrupted
379 if (!Thread.interrupted() &&
420 * given time and the current thread has not been interrupted.
428 * @throws InterruptedException if the current thread is interrupted
435 if (!Thread.interrupted()) {
456 * until available or the current thread is interrupted
1304 cancelWaiter(WNode node, WNode group, boolean interrupted) argument
[all...]
/libcore/luni/src/test/java/libcore/java/io/
H A DInterruptedStreamTest.java50 // Clear the interrupted bit to make sure an earlier test did
52 Thread.interrupted();
61 Thread.interrupted(); // clear interrupted bit
209 // validate and clear interrupted bit before join
211 assertTrue(Thread.interrupted());
/libcore/luni/src/test/java/libcore/java/lang/
H A DOldThreadGroupTest.java245 private static boolean interrupted = false; field in class:OldThreadGroupTest
259 assertFalse("Incorrect state of thread", interrupted);
261 assertFalse("Incorrect state of thread", interrupted);
267 assertTrue("Incorrect state of thread", interrupted);
321 interrupted = true;
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/
H A DThreadTest.java479 boolean interrupted = false;
488 interrupted = true;
490 assertTrue("Failed to Interrupt thread1", interrupted);
492 interrupted = false;
503 interrupted = true;
505 assertTrue("Failed to Interrupt thread2", interrupted);
510 * java.lang.Thread#interrupted()
513 assertFalse("Interrupted returned true for non-interrupted thread", Thread
514 .interrupted());
516 assertTrue("Interrupted returned true for non-interrupted threa
[all...]
/libcore/luni/src/main/java/java/util/concurrent/
H A DPhaser.java63 * waiting thread is interrupted. Interruptible and timeout
703 * value, throwing {@code InterruptedException} if interrupted
714 * @throws InterruptedException if thread interrupted while waiting
735 * InterruptedException} if interrupted while waiting, or
749 * @throws InterruptedException if thread interrupted while waiting
1016 boolean interrupted = Thread.interrupted();
1017 if (interrupted || --spins < 0) { // need node to record intr
1019 node.wasInterrupted = interrupted;
1084 if (Thread.interrupted())
[all...]
H A DExchanger.java326 * @return the other thread's item; or null if interrupted; or
383 if (Thread.interrupted())
419 * was enabled or the thread was interrupted before completion; or
497 * the current thread is {@linkplain Thread#interrupt interrupted}),
516 * <li>has its interrupted status set on entry to this method; or
517 * <li>is {@linkplain Thread#interrupt interrupted} while waiting
521 * interrupted status is cleared.
526 * interrupted while waiting
534 ((Thread.interrupted() || // disambiguates null return
542 * the current thread is {@linkplain Thread#interrupt interrupted} o
[all...]
H A DCyclicBarrier.java96 * {@link InterruptedException} if they too were interrupted at about
181 if (Thread.interrupted()) {
202 // loop until tripped, broken, interrupted, or timed out
215 // been interrupted, so this interrupt is deemed to
297 * <li>has its interrupted status set on entry to this method; or
298 * <li>is {@linkplain Thread#interrupt interrupted} while waiting
301 * interrupted status is cleared.
308 * <p>If any thread is {@linkplain Thread#interrupt interrupted} while waiting,
324 * @throws InterruptedException if the current thread was interrupted
327 * interrupted o
[all...]
H A DSynchronousQueue.java155 * by checking Thread.interrupted.
845 Thread.interrupted();
864 if (!Thread.interrupted())
894 Thread.interrupted();
909 if (e != null || !Thread.interrupted())
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/net/
H A DServerSocketTest.java43 boolean interrupted; field in class:ServerSocketTest
186 interrupted = false;
194 interrupted = true;
214 if (interrupted) {
215 fail("accept interrupted");
222 interrupted = false;
229 interrupted = true;
231 assertTrue("accept not interrupted", interrupted);
/libcore/luni/src/test/java/libcore/java/nio/channels/
H A DFileIOInterruptTest.java93 // Clear the interrupted state, if set.
94 Thread.interrupted();
243 // Check but also clear the interrupted status, so we can wait for the FifoWriter thread in
245 assertTrue(Thread.interrupted());
375 // Check but also clear the interrupted status, so we can wait for the FifoReader thread in
377 assertTrue(Thread.interrupted());
476 wasInterrupted = Thread.interrupted();
513 wasInterrupted = Thread.interrupted();
564 wasInterrupted = Thread.interrupted();
615 wasInterrupted = Thread.interrupted();
[all...]

Completed in 470 milliseconds

123