61 |
|
public boolean isSignalled() { return getState() != 0; } |
62 |
|
|
63 |
|
public long tryAcquireShared(long ignore) { |
64 |
< |
return isSignalled()? 1 : -1; |
64 |
> |
return isSignalled() ? 1 : -1; |
65 |
|
} |
66 |
|
|
67 |
|
public boolean tryReleaseShared(long ignore) { |
477 |
|
} |
478 |
|
|
479 |
|
/** |
480 |
< |
* Timed await without a signal times out |
480 |
> |
* Timed await without a signal times out |
481 |
|
*/ |
482 |
|
public void testAwait_Timeout() throws InterruptedException { |
483 |
|
final Mutex sync = new Mutex(); |
953 |
|
/** |
954 |
|
* acquireSharedTimed returns after release |
955 |
|
*/ |
956 |
< |
public void testAsquireSharedTimed() throws InterruptedException { |
956 |
> |
public void testAcquireSharedTimed() throws InterruptedException { |
957 |
|
final BooleanLatch l = new BooleanLatch(); |
958 |
|
|
959 |
|
Thread t = new Thread(new CheckedRunnable() { |