671 |
|
*/ |
672 |
|
public void testHasWaitersIAE() { |
673 |
|
final Mutex sync = new Mutex(); |
674 |
< |
final AbstractQueuedSynchronizer.ConditionObject c = (sync.newCondition()); |
674 |
> |
final AbstractQueuedSynchronizer.ConditionObject c = sync.newCondition(); |
675 |
|
final Mutex sync2 = new Mutex(); |
676 |
|
try { |
677 |
|
sync2.hasWaiters(c); |
687 |
|
*/ |
688 |
|
public void testHasWaitersIMSE() { |
689 |
|
final Mutex sync = new Mutex(); |
690 |
< |
final AbstractQueuedSynchronizer.ConditionObject c = (sync.newCondition()); |
690 |
> |
final AbstractQueuedSynchronizer.ConditionObject c = sync.newCondition(); |
691 |
|
try { |
692 |
|
sync.hasWaiters(c); |
693 |
|
shouldThrow(); |
703 |
|
*/ |
704 |
|
public void testGetWaitQueueLengthIAE() { |
705 |
|
final Mutex sync = new Mutex(); |
706 |
< |
final AbstractQueuedSynchronizer.ConditionObject c = (sync.newCondition()); |
706 |
> |
final AbstractQueuedSynchronizer.ConditionObject c = sync.newCondition(); |
707 |
|
final Mutex sync2 = new Mutex(); |
708 |
|
try { |
709 |
|
sync2.getWaitQueueLength(c); |
719 |
|
*/ |
720 |
|
public void testGetWaitQueueLengthIMSE() { |
721 |
|
final Mutex sync = new Mutex(); |
722 |
< |
final AbstractQueuedSynchronizer.ConditionObject c = (sync.newCondition()); |
722 |
> |
final AbstractQueuedSynchronizer.ConditionObject c = sync.newCondition(); |
723 |
|
try { |
724 |
|
sync.getWaitQueueLength(c); |
725 |
|
shouldThrow(); |
735 |
|
*/ |
736 |
|
public void testGetWaitingThreadsIAE() { |
737 |
|
final Mutex sync = new Mutex(); |
738 |
< |
final AbstractQueuedSynchronizer.ConditionObject c = (sync.newCondition()); |
738 |
> |
final AbstractQueuedSynchronizer.ConditionObject c = sync.newCondition(); |
739 |
|
final Mutex sync2 = new Mutex(); |
740 |
|
try { |
741 |
|
sync2.getWaitingThreads(c); |
751 |
|
*/ |
752 |
|
public void testGetWaitingThreadsIMSE() { |
753 |
|
final Mutex sync = new Mutex(); |
754 |
< |
final AbstractQueuedSynchronizer.ConditionObject c = (sync.newCondition()); |
754 |
> |
final AbstractQueuedSynchronizer.ConditionObject c = sync.newCondition(); |
755 |
|
try { |
756 |
|
sync.getWaitingThreads(c); |
757 |
|
shouldThrow(); |