554 |
|
|
555 |
|
/** |
556 |
|
* Waits for another thread to arrive at this exchange point (unless |
557 |
< |
* the current thread is {@link Thread#interrupt interrupted}), |
557 |
> |
* the current thread is {@linkplain Thread#interrupt interrupted}), |
558 |
|
* and then transfers the given object to it, receiving its object |
559 |
|
* in return. |
560 |
|
* |
568 |
|
* dormant until one of two things happens: |
569 |
|
* <ul> |
570 |
|
* <li>Some other thread enters the exchange; or |
571 |
< |
* <li>Some other thread {@link Thread#interrupt interrupts} the current |
571 |
> |
* <li>Some other thread {@linkplain Thread#interrupt interrupts} the current |
572 |
|
* thread. |
573 |
|
* </ul> |
574 |
|
* <p>If the current thread: |
575 |
|
* <ul> |
576 |
|
* <li>has its interrupted status set on entry to this method; or |
577 |
< |
* <li>is {@link Thread#interrupt interrupted} while waiting |
577 |
> |
* <li>is {@linkplain Thread#interrupt interrupted} while waiting |
578 |
|
* for the exchange, |
579 |
|
* </ul> |
580 |
|
* then {@link InterruptedException} is thrown and the current thread's |
599 |
|
|
600 |
|
/** |
601 |
|
* Waits for another thread to arrive at this exchange point (unless |
602 |
< |
* the current thread is {@link Thread#interrupt interrupted} or |
602 |
> |
* the current thread is {@linkplain Thread#interrupt interrupted} or |
603 |
|
* the specified waiting time elapses), and then transfers the given |
604 |
|
* object to it, receiving its object in return. |
605 |
|
* |
613 |
|
* dormant until one of three things happens: |
614 |
|
* <ul> |
615 |
|
* <li>Some other thread enters the exchange; or |
616 |
< |
* <li>Some other thread {@link Thread#interrupt interrupts} the current |
617 |
< |
* thread; or |
616 |
> |
* <li>Some other thread {@linkplain Thread#interrupt interrupts} |
617 |
> |
* the current thread; or |
618 |
|
* <li>The specified waiting time elapses. |
619 |
|
* </ul> |
620 |
|
* <p>If the current thread: |
621 |
|
* <ul> |
622 |
|
* <li>has its interrupted status set on entry to this method; or |
623 |
< |
* <li>is {@link Thread#interrupt interrupted} while waiting |
623 |
> |
* <li>is {@linkplain Thread#interrupt interrupted} while waiting |
624 |
|
* for the exchange, |
625 |
|
* </ul> |
626 |
|
* then {@link InterruptedException} is thrown and the current thread's |