org.gudy.azureus2.pluginsimpl.local.utils
Class SemaphoreImpl
java.lang.Object
  
org.gudy.azureus2.pluginsimpl.local.utils.SemaphoreImpl
- All Implemented Interfaces: 
 - Semaphore
 
public class SemaphoreImpl
- extends Object
- implements Semaphore
  
 
 
| Methods inherited from class java.lang.Object | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
SemaphoreImpl
protected SemaphoreImpl(PluginInterface pi)
reserve
public void reserve()
- Specified by:
 reserve in interface Semaphore
 
 
reserveIfAvailable
public boolean reserveIfAvailable()
- Specified by:
 reserveIfAvailable in interface Semaphore
 
 
reserve
public boolean reserve(long timeout_millis)
- Description copied from interface: 
Semaphore 
- reserve a semaphore subject to timeout
- Specified by:
 reserve in interface Semaphore
 
- Parameters:
 timeout_millis - time to wait
- Returns:
 - true -> semaphore reserved, false -> timeout exceeded
 
 
 
release
public void release()
- Specified by:
 release in interface Semaphore
 
 
releaseAllWaiters
public void releaseAllWaiters()
- Specified by:
 releaseAllWaiters in interface Semaphore